Im just trying to figure out how to increment a counter.
eg
Code: Select all
<onLoad>
local count1 = RoMScript("Daily_count()");
</onLoad>
<!-- # 1 --><waypoint x="-20796" z="-22649" y="591"> </waypoint>
<!-- # 2 --><waypoint x="-21125" z="-22420" y="618"> </waypoint>
<!-- # 3 --><waypoint x="-21483" z="-22037" y="597"> </waypoint>
<!-- # 4 --><waypoint x="-21605" z="-21973" y="591"> </waypoint>
<!-- # 5 --><waypoint x="-20393" z="-21331" y="804" tag='Main'>
if 10 > count1 then
queststate = getQuestStatus("Concerned Note");
if queststate == "complete" then
-- Complete quest
player:target_NPC("Shar Talos");
CompleteQuestByName("Concerned Note");
local count1 = local count1 + 1
__WPL:setWaypointIndex(__WPL:findWaypointTag("Main"));
else
-- Accept quest
player:target_NPC("Shar Talos");
AcceptQuestByName("Concerned Note");
__WPL:setWaypointIndex(__WPL:findWaypointTag("Quest"));
else
-- Do Quest
__WPL:setWaypointIndex(__WPL:findWaypointTag("Quest"));
end
else
inventory:update();
player:update();
-- note #202434 is the daily reset card
if inventory:itemTotalCount(202434) >= 1 then
inventory:useItem(202434);
local count1 = 0
__WPL:setWaypointIndex(__WPL:findWaypointTag("Main"));
else
error("No Daily Reset Cards left!")
player:sleep();
end
end