LatSo Posted July 18, 2013 Posted July 18, 2013 Can I please request a script code that can give a character an item/cash points whether he/she is online or OFFLINE. thanks! Quote
Skorm Posted July 18, 2013 Posted July 18, 2013 prontera,206,188,5 script GiveItem 100,{ if(getgmlevel()<10) end; mes .npc$; mes "Hi, I can give items out"; mes "even if the person isn't online O_O"; next; mes .npc$; mes "Please input the persons name."; input(.@a$); next; if(query_sql("SELECT `char_id`,`account_id` FROM `char` WHERE `name` = '"+.@a$+"'",.@char_id,.@account_id)) { if(!isloggedin(.@account_id)) { mes .npc$; mes "I've found ("+.@a$+")!"; mes "What would you like to give them?"; mes "(Input an Itemid)"; next; while(getiteminfo(.@a,2)<0) { input(.@a); dispbottom "Please enter a valid ID!"; } mes .npc$; mes "Now the amount you'd like to send."; input(.@; next; mes .npc$; query_sql("INSERT INTO `inventory` (`char_id`, `nameid`, `amount`, `equip`, `identify`) VALUES ("+.@char_id+", "+.@a+", "+.@b+", 0, 1)"); mes "Item sent!"; } else { mes .npc$; mes "This person seems to be"; mes "online right now."; mes "Would you like me to"; mes "Send the item anyways?"; next; if(select("Yes:No")&2) { mes .npc$; mes "Alright maybe next time"; close; } mes .npc$; mes "Ok input id of the desired item."; while(getiteminfo(.@a,2)<0) { input(.@a); dispbottom "Please enter a valid ID!"; } mes "Now the amount you'd like to send."; input(.@; next; mes .npc$; getitem(.@a,.@b,.@account_id); mes "Item sent!"; } } else { mes .npc$; mes "I can't seem to find that person check your spelling."; } close; OnInit: set .npc$, "[GiveItem]"; } Primitive.... but it's what you want... You could also use @mail or something... 1 Quote
LatSo Posted July 18, 2013 Author Posted July 18, 2013 will test it later! Thanks for the help sir! no.1! Quote
Question
LatSo
Can I please request a script code that can give a character an item/cash points whether he/she is online or OFFLINE.
thanks!
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.