Here is script I have for our Cruor NPC but on the player:startEvent(0x07D2,player:getCruor()); I get call method 'get cruor' (a nil value) what am I missing
-----------------------------------
-- Area: Abyssea-Konschtat
-- NPC: Cruor Prospector
--
-----------------------------------
require("scripts/globals/settings");
package.loaded["scripts/zones/Abyssea-Vunkerl/TextIDs"] = nil;
require("scripts/zones/Abyssea-Vunkerl/TextIDs");
require("scripts/globals/abyssea");
require("scripts/globals/common");
require("scripts/globals/missions");
-----------------------------------
-- onTrade Action
-----------------------------------
function onTrade(player,npc,trade)
end;
-----------------------------------
-- onTrigger Action
-----------------------------------
function onTrigger(player,npc)
player:startEvent(0x07D2,player:getCruor());
print("onEventSelection")
print("onEventSelection - CSID:",csid);
print("onEventSelection - option ===",option);
end;
-----------------------------------
-- onEventUpdate
-----------------------------------
function onEventUpdate(player,csid,option)
-- if (CSID == 0x07D2) then
print("onEventSelection")
print("onEventSelection - CSID:",csid);
print("onEventSelection - option ===",option);
-- end
-- 552
-- printf("CSID: %u",csid);
-- printf("RESULT: %u",option);
end;
-----------------------------------
-- onEventFinish
-----------------------------------
function onEventFinish(player,csid,option)
print("onEventSelection")
print("onEventSelection - CSID:",csid);
print("onEventSelection - option ===",option);
local abysseaTime = player:getVar("Abysseatime");
if (option >= 552) then
cost = 0;
-- printf("CSID: %u",csid);
-- printf("RESULT: %u",option);
end;
Cruor NPC
Re: Cruor NPC
you want
not getCruor()
I've already done partial work on thees, enough that people should be able to copy paste fill in both the missing bits by looking at other NPC scripts and be able to do the same NPC in the other abyssea zones with juts some minor changes (like correcting which KI's are in script to reflect those shown in the in game menu). https://github.com/TeoTwawki/darkstar/b ... or.lua#L28
Most of what I did is already merged into DarkStar with more on its way to pull requests when I have time.
p.s.
Use code tags when posting code. Alternatively, use either pastebin or privatepaste and remember to select the right language parser. Also you pasted code has require lines that you likely will never need in that npc.
Code: Select all
getCurrency("cruor")
I've already done partial work on thees, enough that people should be able to copy paste fill in both the missing bits by looking at other NPC scripts and be able to do the same NPC in the other abyssea zones with juts some minor changes (like correcting which KI's are in script to reflect those shown in the in game menu). https://github.com/TeoTwawki/darkstar/b ... or.lua#L28
Most of what I did is already merged into DarkStar with more on its way to pull requests when I have time.
p.s.
Use code tags when posting code. Alternatively, use either pastebin or privatepaste and remember to select the right language parser. Also you pasted code has require lines that you likely will never need in that npc.
Hi, I run The Demiurge server.
Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live. - Martin Golding
Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live. - Martin Golding
DO NOT PRIVATE MESSAGE ME ABOUT BUGSPLS USE [ code ] CODE TAGS [ /code ] WHEN POSTING CODE
Re: Cruor NPC
Ok thanks. Some of this was just from old server files was working on and came across it and wanted to see if it work
[GM] Soulsin