events/events.xml@Sarah Wesker
Where install ??
creaturescripts?
in the folder date does not have this folder event / ...
Do you need to tag in the monster file?
<script> <event name = "creature" /> </ script>
function onCombat(cid, target)
if isMonster(target) and isPlayer(cid) then
if getCreatureName(target) == "Demon" and getCreatureStorage(cid, 1000) == 1 then
return false
end
end
return true
end
registerCreatureEvent(cid, "monsterProtected")
<event type="combat" name="monsterProtected" event="script" value="monsterProtected.lua"/>
of storage?@Sarah Wesker
THANKS!!!!!
its worked....
How to put more than 1 value? or is it put 1, 2, 3, .......?
getCreatureStorage(cid, 1000) >= 1
it doesn't work in version 1.4 but there is no bug eitherevents/events.xml
events/scripts/creature.lua
Code:<event class="Creature" method="onTargetCombat" enabled="1" />
View attachment 36867Code:if self:isPlayer() and target:isMonster() and target:getName() == "Demon" and self:getStorageValue(1000) == 1 then return RETURNVALUE_NOTPOSSIBLE end
this it should work