• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

HELP Task System

Lokizs

New Member
Joined
Sep 21, 2013
Messages
16
Reaction score
3
Hi people, I trying use a task system based in global system, but whenever I kill a monster, it does not change the questlog, always remains at 0.
help.png


I tried to put scripts here but it appeared that it was too big, so if anyone can put scripts without bugs for me I'd appreciate it. Did the quest log from updating to kill the monster.
Thanks for the help everyone!

(I use TFS 1.0 - http://otland.net/threads/10-37-real-map-server-with-roshamuul-tfs-1-0.212019/ but the task system is http://otland.net/threads/10-37-real-map-server-with-roshamuul-tfs-1-0.212019/)
 
Last edited by a moderator:
You linked the same server? I guess you use printers system and its not that good tbh, I think he downloaded it from otland and that script is pretty much a "5 min job so I can release it on otland"...
You would have to rewrite the whole project, id say atleast grizzly adams since the lib file is all fucked there.
I used another lib file when I rewrote mine can't remember where I found it was some other 9.x server or 10.x and that server had a better lib file since it used a variable to check the boolean value if its a grizzly mission or not.

But at this topic, you need to check your creaturescript that handles the killing of the creature. Should be something like p:setStorageValue(storage + p:getStorageValue(storage))
 
This is my creaturescript :

dofile('data/lib/killingInTheNameOfQuest.lua')

function onKill(cid, target, lastHit)
local started = getPlayerStartedTasks(cid)
if isPlayer(target) or isSummon(target) then return true end
if started and #started > 0 then
for _, id in ipairs(started) do
if isInArray(tasks[id].creatures, getCreatureName(target):lower()) then
if getPlayerStorageValue(cid, KILLSSTORAGE_BASE + id) < tasks[id].killsRequired then
setPlayerStorageValue(cid, KILLSSTORAGE_BASE + id, getPlayerStorageValue(cid, KILLSSTORAGE_BASE + id) + 1)
end
end
end
end
return true
end
 
Back
Top