Jump to content

Question

Posted

I want to edit itemdb.txt

so I want to make a random item when clicked on it to one of the 7 items.

12986,Pet_Egg_Scroll_Box9,Adventurer Pack Box,2,,,10,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem rand(25194,25195,25197,25199,25202,25203,25205),1; },{},{}

I question why there is writing a error server after restart server :

"Parse_CallFunc Expeted ')' to close argument list"

if anyone can help gave the solution? thanks.

6 answers to this question

Recommended Posts

Posted

Item_db.txt :

12986,Pet_Egg_Scroll_Box9,Adventurer Pack Box,2,,,10,,,,,0xFFFFFFFF,7,2,,,,,,{ callfunc "CustomBoxUpper"; },{},{}

Script :

function script CustomBoxUpper {

setarray .BoxItems[0],25194,25195,25197,25199,25202,25203,25205;

set .Random, getarraysize( .BoxItems );

getitem .BoxItems[ rand( .Random ) ], 1;

announce "["+strcharinfo(0)+"] baru saja memperoleh ["+getitemname(.BoxItems[ rand(.Random) ])+"] dari Custom Box.",0;

end;

}

why when I opened the box the item out of default? not the item that I make in the script? please solution, thank you.

Posted

Default item -> 12992

12986,Pet_Egg_Scroll_Box9,Adventurer Pack Box,2,,,10,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem 12992,1; },{},{}

Custom Item -> 25194,25195,25197,25199,25202,25203,25205

12986,Pet_Egg_Scroll_Box9,Adventurer Pack Box,2,,,10,,,,,0xFFFFFFFF,7,2,,,,,,{ callfunc "CustomBoxUpper"; },{},{}

I have @ reloaditemdb

the same result.

I still get the default item instead of a custom item.

I was sorry item_db.txt error, if you could share item_db.txt? Thank you.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...