Issue Information
-
#007968
-
0 - None Assigned
-
Fixed
Issue Confirmations
-
Yes (0)No (1)
Moving the issue from Script to here, since im fearing is an core problem.
Check last git, edit npc/scripts_custom.conf to add "npc: doc/sample/npc_trader_sample.txt " and start map server.
Tried editing the npc, getting a piece of that on a new npc...
[Notice]: Conflicting var name 'Red_Potion', prioritising the script var [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_MARKET' [Debug]: Source (NPC): HaiMarket at prontera (150,160) [Warning]: script_get_val: cannot access player variable 'NST_MARKET', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_CUSTOM' [Debug]: Source (NPC): TestCustom2 at prontera (153,152) [Warning]: script_get_val: cannot access player variable 'NST_CUSTOM', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_CASH' [Debug]: Source (NPC): TestTraderCash at prontera (152,152) [Warning]: script_get_val: cannot access player variable 'NST_CASH', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#ve at ve_in (243,303) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#ve at ve_in (243,303) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#tu at tur_dun01 (158,54) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#tu at tur_dun01 (158,54) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#ra at ra_in01 (257,269) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#ra at ra_in01 (257,269) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#prt1 at prt_in (126,76) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#prt1 at prt_in (126,76) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#prt at prt_fild05 (290,221) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#prt at prt_fild05 (290,221) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#pay3 at payon (159,96) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#pay3 at payon (159,96) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#pay2 at payon_in02 (87,34) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#pay2 at payon_in02 (87,34) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#pay at payon_in01 (5,49) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#pay at payon_in01 (5,49) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#mosk at mosk_in (21,254) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#mosk at mosk_in (21,254) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#moc2 at moc_ruins (114,63) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#moc2 at moc_ruins (114,63) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#moc1 at moc_ruins (91,128) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#moc1 at moc_ruins (91,128) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#xmas at xmas_in (40,38) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#xmas at xmas_in (40,38) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#lou at lou_in02 (239,176) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#lou at lou_in02 (239,176) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#lhz2 at lhz_in03 (239,106) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#lhz2 at lhz_in03 (239,106) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#yuno2 at yuno_in01 (25,34) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#yuno2 at yuno_in01 (25,34) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#yuno at yuno (218,97) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#yuno at yuno (218,97) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#hu at hu_in01 (241,368) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#hu at hu_in01 (241,368) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#gon at gonryun (147,84) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#gon at gonryun (147,84) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#gef at geffen_in (77,167) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#gef at geffen_in (77,167) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Paddler#ein at einbroch (82,199) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Paddler#ein at einbroch (82,199) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#ein at ein_in01 (189,15) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#ein at ein_in01 (189,15) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#cmd2 at cmd_fild07 (257,126) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#cmd2 at cmd_fild07 (257,126) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#cmd at cmd_in01 (79,182) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#cmd at cmd_in01 (79,182) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#ayo at ayo_in01 (18,182) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#ayo at ayo_in01 (18,182) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#ama at ama_in01 (24,30) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#ama at ama_in01 (24,30) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#alde at aldeba_in (94,56) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#alde at aldeba_in (94,56) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#alb2 at alberta_in (182,97) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'! [Debug]: Source (NPC): Tool Dealer#alb2 at alberta_in (182,97) [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: sellitem (1 parameter): [Debug]: Data: variable name='Red_Potion' [Debug]: Source (NPC): Tool Dealer#alb at alb2trea (87,65) [Warning]: script_get_val: cannot access player variable 'Red_Potion', defaulting to 0 [Warning]: buildin_sellitem: unknown item id '0'!STEPS TO REPRODUCE:
Check last git, edit npc/scripts_custom.conf to add "npc: doc/sample/npc_trader_sample.txt " and start map server.
Tried editing the npc, getting a piece of that on a new npc...
I can't reproduce this. Did you recompile your server?
Yes, and its weird, as i said, i got from github last version.
I cleaned, configure'd and ran make sql..
I cleaned, configure'd and ran make sql..
Edited by Moguri, 12 January 2014 - 06:58 PM.
Uploaded full debug of mapserver, just edited the ips
Attached Files
Do you ahve any custom scripts where you use a variable named 'Red_Potion'?
This shouldn't normally happen:
This shouldn't normally happen:
[Notice]: Conflicting var name 'Red_Potion', prioritising the script var
As i said, i made a checkout on a fresh git, so i didnt added any npc... Just the default ones
could you send us your db/const.txt? also could you inform us your operating system?
Of course!
Db/const.txt is the default one, no changes.
And the SO its Debian 7
Db/const.txt is the default one, no changes.
And the SO its Debian 7
changed status to: Fixed
Thanks for the fix, but still happends another thing:
Got this:
Got this:
[Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_MARKET' index=0 [Debug]: Source (NPC): HaiMarket at prontera (150,160) [Warning]: script_get_val: cannot access player variable 'NST_MARKET', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_CUSTOM' index=0 [Debug]: Source (NPC): TestCustom2 at prontera (153,152) [Warning]: script_get_val: cannot access player variable 'NST_CUSTOM', defaulting to 0 [Error]: script_rid2sd: fatal error ! player not attached! [Debug]: Function: tradertype (1 parameter): [Debug]: Data: variable name='NST_CASH' index=0 [Debug]: Source (NPC): TestTraderCash at prontera (152,152) [Warning]: script_get_val: cannot access player variable 'NST_CASH', defaulting to 0And all the npcs are selling the items for Zeny, not cash or other things
The sample NPCs in doc/sample/npc_trader_sample.txt uses NST_CASH and NST_CUSTOM.
But still, no matter what the NPCs are using, those constants are supposed to be defined in db/const.txt, so they shouldn't throw any errors. If your const.txt file is complete and up to date, then this shouldn't happen. Compare with:
https://github.com/H...const.txt#L3353
But still, no matter what the NPCs are using, those constants are supposed to be defined in db/const.txt, so they shouldn't throw any errors. If your const.txt file is complete and up to date, then this shouldn't happen. Compare with:
https://github.com/H...const.txt#L3353
Its copied to be like that, maybe this is the problem?
That's the problem.
BTW, the script uses NST_CASH, NST_CUSTOM and NST_MARKET
[Error]: script_rid2sd: fatal error ! player not attached!Seems that the npc is trying to get a player's Variable when using tradertype(xxx);
That's the problem.
BTW, the script uses NST_CASH, NST_CUSTOM and NST_MARKET
It says it's trying to use a player variable because, for some reason, it doesn't know those constants. As I said, this can only happen if they're not listed in db/const.txt (or if for some reason the server is unable to read that file correctly)
Ok, my bad, for some reason the format was not ok, or something, deleted, then restored the file and now its working