Night Wolf's best answers

  • Night Wolf

    experience cast open

    before function onSay define: local storage = 17754 -- exp storage now before player:sendTextMessage(MESSAGE_INFO_DESCR, "You have started casting your gameplay."): player:setStorageValue(storage, 1) and before player:sendTextMessage(MESSAGE_INFO_DESCR, "You have stopped casting your...
  • Night Wolf

    Lua NPC set storage after player sells item

    if isInArray({7618, 7620}, itemid) then player:setStorageValue(storage, 1) return true end Just remove the if and the first end. player:setStorageValue(storage, 1) return true But this is when you buy an item, switch to callback onSell (you can keep the same function name, just have to...
  • Night Wolf

    Custom spellbook

    look this: if getPlayerVocation(cid) == 1 or 5 or 9 then Every number above 0 in Lua is considered as True so basically you're saying if vocation == 1 OR true OR true then anything OR true is equal true, that's why. If you want to check multiple vocations you gotta repeat the comparison: if...