Budots Posted December 23, 2013 Posted December 23, 2013 Hi Guys, Since Christmas is fast approaching, i would like to request a Simple Summoner script, - Summons 100 Santa Poring - Randomly around Prontera Town - 70 Normal Santa Porings = drops 1 9524 per monster // 9524 <--- item id - 30 Special Santa Porings = drops 1 Proof of Donation per monster - Runs every 2 hours - Announces when summoning starts - Announces how many Special Santa Porings left. THANKS IN ADVANCE AND A MERRY MERRY CHRISTMAS /ho bump Quote
AnnieRuru Posted December 23, 2013 Posted December 23, 2013 - script asdf -1,{ OnMinute00: if ( gettime(3) % 2 ) end; announce "summoning start", bc_all; killmonster "prontera", strnpcinfo(0)+"::Onnormal"; killmonster "prontera", strnpcinfo(0)+"::Onspecial"; .count = 30; monster "prontera", 0,0, "--ja--", 1062,70, strnpcinfo(0)+"::Onnormal"; monster "prontera", 0,0, "--ja--", 1062,30, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 9524, 1; end; Onspecial: getitem 7179, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; } Quote
Tepoo Posted December 23, 2013 Posted December 23, 2013 Thats Pretty Nice Annie, i dont need it but you showed me some new tricks for writing npcs. thanks you very much :-) Quote
Budots Posted December 23, 2013 Author Posted December 23, 2013 - script asdf -1,{ OnMinute00: if ( gettime(3) % 2 ) end; announce "summoning start", bc_all; killmonster "prontera", strnpcinfo(0)+"::Onnormal"; killmonster "prontera", strnpcinfo(0)+"::Onspecial"; .count = 30; monster "prontera", 0,0, "--ja--", 1062,70, strnpcinfo(0)+"::Onnormal"; monster "prontera", 0,0, "--ja--", 1062,30, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 9524, 1; end; Onspecial: getitem 7179, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; } Thanks Annie Quote
Kami675 Posted December 24, 2013 Posted December 24, 2013 (edited) - script asdf -1,{ OnMinute00: if ( gettime(3) % 2 ) end; announce "summoning start", bc_all; killmonster "prontera", strnpcinfo(0)+"::Onnormal"; killmonster "prontera", strnpcinfo(0)+"::Onspecial"; .count = 30; monster "prontera", 0,0, "--ja--", 1062,70, strnpcinfo(0)+"::Onnormal"; monster "prontera", 0,0, "--ja--", 1062,30, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 9524, 1; end; Onspecial: getitem 7179, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; } well i edited ur script a lil bit and now it doesnt work...xD. What did I do wrong? - script asdf -1,{ OnMinute00: if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; .count = 50; monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; } Edited December 24, 2013 by Kami675 Quote
AnnieRuru Posted December 24, 2013 Posted December 24, 2013 perhaps you need to learn some script debugging - script asdf -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; .count = 50; monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }I tested it , it work fine Quote
Kami675 Posted December 24, 2013 Posted December 24, 2013 (edited) perhaps you need to learn some script debugging - script asdf -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; .count = 50; monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; .count--; if ( .count ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }I tested it , it work fine Sorry I just recently got an interest in ragnarok scripting so i'm starting from scratch xD.I'm getting this error atm [Error]: script error on /home/*******/trunk/npc/custom/Xmasevent.txt line 8 parse_line: expect command, missing function name or calling undeclared function 3 : OnWhisperGlobal: 4 : if ( gettime(3) % 4 ) end; 5 : announce "Xmas Event Has Started at xmas town!", bc_all; 6 : killmonster "xmas", strnpcinfo(0)+"::Onnormal"; 7 : killmonster "xmas", strnpcinfo(0)+"::Onspecial"; * 8 : '.'count = 50; 9 : monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; 10 : monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; 11 : end; 12 : Onnormal: 13 : getitem 7034, 1; Edited December 24, 2013 by Kami675 Quote
AnnieRuru Posted December 24, 2013 Posted December 24, 2013 hmm ... I usually don't teach newbies ... but feel like want to make an exemption today - script xmas_event -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; set .count, 50; monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; set .count, .count -1; if ( .count > 0 ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }the reason my script not working in your emulator is probably because you are using very outdated emulator, maybe you are using eathenahttp://rathena.org/board/topic/62395-r15982-script-engine-update/ ... you know .. you reminded me that I also said something like "I want to learn scripting too!" back in 2006 ... feeling nostalgic... ...or maybe you just said something moved my heart lol Quote
Kami675 Posted December 24, 2013 Posted December 24, 2013 (edited) hmm ... I usually don't teach newbies ... but feel like want to make an exemption today - script xmas_event -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; set .count, 50; monster "xmas", 0,0, "--ja--", 1247,150, strnpcinfo(0)+"::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, strnpcinfo(0)+"::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; set .count, .count -1; if ( .count > 0 ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }the reason my script not working in your emulator is probably because you are using very outdated emulator, maybe you are using eathenahttp://rathena.org/board/topic/62395-r15982-script-engine-update/ ... you know .. you reminded me that I also said something like "I want to learn scripting too!" back in 2006 ... feeling nostalgic... ...or maybe you just said something moved my heart lol xD Yea i've been playing ragnarok for more than a decade it's sad that I just now want to learn scripting. I want to learn more about scripting before I go ahead and attempt to create a big server of my own. I really do appreciate the help I still have a long way to go though =/ lol. As for now i'm just testing the waters haha. Also, I am using an old emulator i'm using eAthena 15262M. As for the script how would I go about "downgrading" it to support eAthena? Edited December 24, 2013 by Kami675 Quote
AnnieRuru Posted December 24, 2013 Posted December 24, 2013 (edited) 15262... <.< I don't think it even support strnpcinfo... - script xmas_event -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", "xmas_event::Onnormal"; killmonster "xmas", "xmas_event::Onspecial"; set .count, 50; monster "xmas", 0,0, "--ja--", 1247,150, "xmas_event::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, "xmas_event::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; set .count, .count -1; if ( .count > 0 ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }this should work in your *outdated* emulatorhttp://www.eathena.ws/board/index.php?showtopic=276056 ... getting nostalgic ... actually, scripting is just a part of it you can also try mapping, or making palettes ... these are some professions that you can contribute rathena also, once you truly wish to master a profession, its a never ending process ... after scripting for 7 years I still feel I haven't finish learning yet =/ Edited December 24, 2013 by AnnieRuru Quote
Kami675 Posted December 24, 2013 Posted December 24, 2013 15262... <.< I don't think it even support strnpcinfo... - script xmas_event -1,{ OnMinute00: OnWhisperGlobal: // if ( gettime(3) % 4 ) end; announce "Xmas Event Has Started at xmas town!", bc_all; killmonster "xmas", strnpcinfo(0)+"::Onnormal"; killmonster "xmas", strnpcinfo(0)+"::Onspecial"; set .count, 50; monster "xmas", 0,0, "--ja--", 1247,150, "xmas_event::Onnormal"; monster "xmas", 0,0, "--ja--", 1247,50, "xmas_event::Onspecial"; end; Onnormal: getitem 7034, 1; end; Onspecial: getitem 7176, 1; set .count, .count -1; if ( .count > 0 ) announce "special poring left "+ .count, bc_map; else announce "all special poring killed", bc_map; end; }this should work in your *outdated* emulatorhttp://www.eathena.ws/board/index.php?showtopic=276056 ... getting nostalgic ... actually, scripting is just a part of it you can also try mapping, or making palettes ... these are some professions that you can contribute rathena WOW! Thanks a ton. lol I like your "if you learn to script straight away in a live server, its like a frog under a well" comment. I plan on as i said before test the waters and see what comes easiest to me(scripting/spriting/mapping/etc) . But as for the script doesn't the // disable that line? so // if ( gettime(3) % 4 ) end; Wouldn't the // disable that line? so it wouldnt occur every 4 hrs? should I remove the //? Quote
AnnieRuru Posted December 24, 2013 Posted December 24, 2013 I usually ignore this kind of question ... but right now couldn't turn eyes away from this topic lol https://github.com/rathena/rathena/blob/master/doc/script_commands.txt#L99 http://www.eathena.ws/board/index.php?showtopic=244209 http://rathena.org/board/topic/64418-script-editors-notepad-rathena-custom-syntax-highlight/ setup test server .. @reloadscript ... use latest rathena ... memorize script_commands.txt ... read wiki .. the rest are common sense already 1 Quote
Kami675 Posted December 24, 2013 Posted December 24, 2013 I usually ignore this kind of question ... but right now couldn't turn eyes away from this topic lol https://github.com/rathena/rathena/blob/master/doc/script_commands.txt#L99 http://www.eathena.ws/board/index.php?showtopic=244209 http://rathena.org/board/topic/64418-script-editors-notepad-rathena-custom-syntax-highlight/ setup test server .. @reloadscript ... use latest rathena ... memorize script_commands.txt ... read wiki .. the rest are common sense already Ohhh ok derp >_< im sorry for the stupid question thanks for clearing it up. I really appreciate the help, thanks once again and to the creator of this topic(Budots) I apologize for the extension of this topic XD. Quote
Question
Budots
Hi Guys,
Since Christmas is fast approaching,
i would like to request a Simple Summoner script,
- Summons 100 Santa Poring
- Randomly around Prontera Town
- 70 Normal Santa Porings = drops 1 9524 per monster // 9524 <--- item id
- 30 Special Santa Porings = drops 1 Proof of Donation per monster
- Runs every 2 hours
- Announces when summoning starts
- Announces how many Special Santa Porings left.
THANKS IN ADVANCE AND A MERRY MERRY CHRISTMAS
/ho 
bump
12 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.