

screamsoflust
Members-
Posts
10 -
Joined
-
Last visited
Content Type
Profiles
Forums
Downloads
Jobs Available
Server Database
Third-Party Services
Top Guides
Store
Crowdfunding
Everything posted by screamsoflust
-
[EDITED] headgear sprite changer
screamsoflust replied to screamsoflust's question in Scripting Support
bump -
[EDITED] headgear sprite changer
screamsoflust replied to screamsoflust's question in Scripting Support
sorry, bump again. -
[EDITED] headgear sprite changer
screamsoflust replied to screamsoflust's question in Scripting Support
bump -
EDIT: I saw this script and tried it out, and it works fine with some little tweaks. basically this script changes the headgear sprite when you whisper the npc what I want to ask is how can I remove the sprite when I remove the headgear? coz when I remove the headgear, the disguise sprite is still there. //Morphogenic Hat Script //Allows a player to change their look to absolutely any hat available or to a defined upper limit. Check the "OnInit" label for information on this. // //By Slam - script Morpho -1,{ OnWhisperGlobal: goto Validation_whisp; end; Validation_whisp: set .@var0$, @whispervar0$; set .@var1$, @whispervar1$; // set .@i,0; // while(.@i < getarraysize(.morpho_disallowed)){ // if(@whispervar1$ == .morpho_disallowed$[.@i]){ // goto denied_unauthorized; // } else { // set .@i,.@i+1; // } // } set .@ii,0; while(.@ii < 6){ if(@whispervar0$ == .keywords$[.@ii]){ goto keyword; } set .@ii,.@ii+1; } dispbottom "---------------[Morphohat Helper]---------------"; dispbottom " "; dispbottom "Sorry, I didn't understand the option you have"; dispbottom "have given me. Please type 'help' for more info"; dispbottom " "; end; keyword: switch(.@ii){ case 0: goto help; case 1: goto tophead; case 2: goto midhead; case 3: goto lowhead; case 4: goto clear; case 5: goto info; } help: dispbottom "---------------[Morphohat Helper]---------------"; dispbottom " "; dispbottom "Welcome to the Morphohat Settings NPC!"; dispbottom "I can help you set what your Morphohat looks like"; dispbottom " "; dispbottom "To use this NPC, whisper NPC:Morpho (you should"; dispbottom "know this already) with upper/middle/lower or "; dispbottom "wing. The wing section is not yet implemented"; dispbottom "however. Now, to set your Morphohat use the "; dispbottom "following layout:"; dispbottom " "; dispbottom "upper#5232 - This will make it a Pink Kitty"; dispbottom " "; dispbottom "Protip: Use RateMyServer.net for item IDs."; end; tophead: if(!isequipped(.top_morpho)){ goto wrong_headgear; } set .@viewid,getiteminfo(.@var1$,11); set .@equipslot,getiteminfo(.@var1$,5); // if(.@equipslot != 256 && .@equipslot != 768){ //Upper and Upper+Mid Only. Comment out this line and the two below it to remove this functionality. // goto denied_wrongslot; // } set viewid_top,.@viewid; if(.@viewid != 0 && .@viewid != -1){ dispbottom "Selected headgear ID: "+.@viewid; setlook 4,.@viewid; } else { dispbottom "Invalid headgear ID."; } end; midhead: if(!isequipped(.mid_morpho)){ goto wrong_headgear; } set .@viewid,getiteminfo(.@var1$,11); set .@equipslot,getiteminfo(.@var1$,5); // if(.@equipslot != 512 && .@equipslot != 513){ //Mid and Mid+Lower only. Comment out this line and the two below it to remove this functionality. // goto denied_wrongslot; // } set viewid_mid,.@viewid; if(.@viewid != 0 && .@viewid != -1){ dispbottom "Selected headgear ID: "+.@viewid; setlook 5,.@viewid; } else { dispbottom "Invalid headgear ID."; } end; lowhead: if(!isequipped(.low_morpho)){ goto wrong_headgear; } set .@viewid,getiteminfo(.@var1$,11); set .@equipslot,getiteminfo(.@var1$,5); // if(.@equipslot != 1){ // Lower Only. Comment out this line and the two below it to remove this functionality. // goto denied_wrongslot; // } set viewid_low,.@viewid; if(.@viewid != 0 && .@viewid != -1){ dispbottom "Selected headgear ID: "+.@viewid; setlook 3,.@viewid; } else { dispbottom "Invalid headgear ID."; } end; clear: set viewid_low, 0; set viewid_mid, 0; set viewid_top, 0; if (getequipid(1) == .top_morpho) setlook 5,0; if (getequipid(9) == .mid_morpho) setlook 4,0; if (getequipid(10) == .low_morpho) setlook 3,0; dispbottom "Your Morphing Hats list has been cleared."; end; info: dispbottom "---------------[Morphohat Helper]---------------"; dispbottom " "; dispbottom "You currently have the following items set for your Morpho hat:"; dispbottom "Upper - "+viewid_top; dispbottom "Middle - "+viewid_mid; dispbottom "Lower - "+viewid_low; end; denied_wrongslot: dispbottom "Sorry, this headgear was not designed for this headgear slot."; end; denied_unauthorized: dispbottom "Sorry, you cannot change your Morphohat into this headgear. Please try another."; end; wrong_headgear: dispbottom "Sorry, you do not currently have your Morphohat equipped. Please equip it and try again!"; end; OnInit: //Array of keywords for the script setarray .keywords$[0],"help","upper","middle","lower","clear","info","wing"; //Change this to the upper limit of the headgears that you wish to make available setarray .morpho_disallowed$[0],"9001","5386","5387","5391","5394","5407","5408","5419","5428","5436","5437","5438","5439","5440","5441","5442","5443","5444","5445","5446","5447","5448","5449","5459","5481","5486","5487","5488","5492","5493","5494","5495","5508","5516","5517","5520","5532","5533","5534","5535","5540","5541","5542","5543","5544","5551","5552","5553","5560","5561","5562","5571","5575","5576","5577","5578","5583","5584","5587","5595","5600","5601","5602","5603","5604","5605","5606","5607","5608","5609","5610","5611","5612","5613","5614","5615","5616","5617","5618","5619","5620","5621","5622","5623","5624","5625","5626","5627","5628","5629","5630","5631","5632","5633","5634","5635","5636","5637","5638","5639","5640","5641","5642","5643","5644","5645","5646","5647","5648","5649","5650","5651","5652","5653","5654","5655","5656","5657","5658","5659","5660","5661","5662","5663","5664","5665","5666","5667","5668","5669","5670","5671","5672","5673","5674","5675","5676","5677","5678","5679","5680","5681","5682","5683","5684","5685","5686","5687","5688","5689","5690","5691","5692","5693","5694","5695","5696","5697","5698","5699","5700","5701","5702","5703","5704","5705","5706","5707","5708","5709","5710","5711","5712","5713","5714","5715","5716","5717","5718","5719","5720","5721","5722","5723","5724","5725","5726","5727","5728","5729","5730","5731","5732","5733","5734","5735","5736","5737","5738","5739","5740","5741","5742","5743","5744","5745","5746","5747","5748","5749","5750","5751","5752","5753","5754","5755","5756","5757","5758","5759","5760","5761","5762","5763","5764","5765","5766","5767","5768","5769","5770","5771","5772","5773","5774","5775","5776","5777","5778","5779","5780","5781","5782","5783","5784","5785","5786","5787","5788","5789","5790","5791","5792","5793","5794","5795","5796","5797","5798","5799","5809","5812","5814","5824","23134","5070"; //inb4OVERNINETHOUSAND //Equip IDs - Change these to the ID numbers of the hat you wish to designate as the Morphing hat set .top_morpho,25092; set .mid_morpho,25093; set .low_morpho,25094; end; } //Use 'callfunc "MorphoEquip",<1,2,3>;' for the "OnEquip" script to let people know that they need to set the view ID or to set the viewid if the person has already set one. //If you wish to make the "Morph" an Account bound variable, simply change all instances of "viewid_" with "#viewid_" function script MorphoEquip { set .@equipslot,getarg(0); switch(.@equipslot) { case 1: //Upper if (!uppernotify) { dispbottom "No headgear set for upper. PM \"NPC:Morpho\" with the word \"help\" for more information."; set uppernotify,1; end; } setlook 4,viewid_top; end; case 2: //Mid if (!middlenotify) { dispbottom "No headgear set for middle. PM \"NPC:Morpho\" with the word \"help\" for more information."; set middlenotify,1; end; } setlook 5,viewid_mid; end; case 3: //Lower if (!lowernotify) { dispbottom "No headgear set for lower. PM \"NPC:Morpho\" with the word \"help\" for more information."; set lowernotify,1; end; } setlook 3,viewid_low; end; } }
-
hi there, I need help with my script on pvp spree announcer, we are trying to make it like dota for every spree. like this: Killing spree--3 kills without dying Dominating--4 kills without dying Mega kill--5 kills without dying Unstoppable--6 kills without dying Wicked sick--7 kills without dying Monster kill--8 kills without dying Godlike--9 kills without dying Beyond Godlike--10 kills without dying, will display each kill thereafter until they die. but on my script you only need to kill 2-3 times to show beyond godlike. can you please help me? here is my script: // spree PVP , GvG Ladder - script keitenai_pvp_ladder -1,{ OnInit: set .announce_on,1; // sets announcement on/off 1/0 set .killstreak,3; // Kill amount to announce Killing Spree set .godlike,.killstreak * 2; // How many KillStreak to announce Godlike set .owning,.killstreak * 3; // How many KillStreak to announce Owning! set $deathcounter,0; // Include Player Death counter or not end; OnPCDieEvent: if(!$deathcounter) end; if(rid2name(killerrid) == rid2name(killedrid)) end; if ( (strcharinfo(3)=="prtg_cas01")|| (strcharinfo(3)=="prtg_cas02")|| (strcharinfo(3)=="prtg_cas03")|| (strcharinfo(3)=="prtg_cas04")|| (strcharinfo(3)=="prtg_cas05") ){ if(getcharid(2)){ if(query_sql("SELECT guild_id FROM gvg_ladder WHERE guild_id='"+getcharid(2)+"'",.@gid)){ //announce "'"+strcharinfo(0)+"' of [ "+strcharinfo(2)+" ] guild has been slained.",0; query_sql("SELECT mem_death FROM gvg_ladder WHERE guild_id='"+getcharid(2)+"'",.@mem_death); query_sql("UPDATE gvg_ladder SET mem_death='"+(.@mem_death +1)+"' WHERE guild_id='"+getcharid(2)+"'"); } else query_sql("INSERT INTO gvg_ladder SET guild_id='"+getcharid(2)+"',mem_kill='0', mem_death='1', gvg_win='0', gvg_lose='0'"); } } set kDEAD,kDEAD+1; if(PCStreak){ set PCStreak,0; set PCKillStreak,0; set $@streakEndName$,strcharinfo(0); } end; OnPCKillEvent: if(rid2name(killerrid) == rid2name(killedrid)) end; if( (strcharinfo(3)=="prtg_cas01")|| (strcharinfo(3)=="prtg_cas02")|| (strcharinfo(3)=="prtg_cas03")|| (strcharinfo(3)=="prtg_cas04")|| (strcharinfo(3)=="prtg_cas05") ){ if(getcharid(2)){ if(query_sql("SELECT guild_id FROM gvg_ladder WHERE guild_id='"+getcharid(2)+"'",.@gid)){ query_sql("SELECT mem_kill FROM gvg_ladder WHERE guild_id='"+getcharid(2)+"'",.@mem_kill); query_sql("UPDATE gvg_ladder SET mem_kill='"+(.@mem_kill +1)+"' WHERE guild_id='"+getcharid(2)+"'"); } else query_sql("INSERT INTO gvg_ladder SET guild_id='"+getcharid(2)+"',mem_kill='1', mem_death='0', gvg_win='0', gvg_lose='0'"); } } set kKILL,kKILL+1; if(.announce_on){ set PCKillStreak,PCKillStreak +1; if(PCKillStreak == .killstreak){ announce "[ "+strcharinfo(0)+" ] is on 'KILLING SPREE' in '"+strcharinfo(3)+"'",bc_blue; set PCStreak,PCStreak +1; } if(PCKillStreak > (.godlike-1)){ announce "[ "+strcharinfo(0)+" ] is BEYOND GODLIKE! Someone KILL "+( (sex)?"HIM":"HER" )+"! in '"+strcharinfo(3)+"'",bc_blue; if(PCStreak==1) set PCKillStreak,PCKillStreak - .killstreak; set PCStreak,PCStreak +1; } if(PCKillStreak > (.owning-1)){ announce "[ "+strcharinfo(0)+" ] is 'OWNING' in '"+strcharinfo(3)+"'",bc_blue; if(PCStreak>1) set PCKillStreak,PCKillStreak - .godlike; set PCStreak,PCStreak +1; } sleep2 1; if($@streakEndName$ == rid2name(killedrid)){ announce "[ "+strcharinfo(0)+" ] has ended "+$@streakEndName$+"'s 'GODLIKE' in '"+strcharinfo(3)+"'",bc_blue; set $@streakEndName$,""; } } end; } prontera,151,203,5 script GVG Ladder 837,{ query_sql("SELECT guild_id, mem_kill, mem_death, gvg_win, gvg_lose FROM gvg_ladder ORDER BY CAST(`gvg_ladder`.`mem_kill` AS UNSIGNED) DESC LIMIT 5",.@gid,.@kill,.@death,.@gvgwin,.@gvglose); mes "[ ^00568A GvG Kill Count ^000000 ]"; mes " "; for( set .@KCs,0; .@KCs<=4; set .@KCs,.@KCs+1 ){ mes "^0000FF"+(.@KCs+1)+".^000000 "+getguildname(.@gid[.@KCs])+" : ^FF0000"+.@kill[.@KCs]+"^000000 Kill(s)"; } if(!$deathcounter) end; else next; query_sql("SELECT guild_id, mem_kill, mem_death, gvg_win, gvg_lose FROM gvg_ladder ORDER BY CAST(`gvg_ladder`.`mem_death` AS UNSIGNED) DESC LIMIT 5",.@gid,.@kill,.@death,.@gvgwin,.@gvglose); mes "[ ^00568A GvG Death Count ^000000 ]"; mes " "; for( set .@DCs,0; .@DCs<=4; set .@DCs,.@DCs+1 ){ mes "^0000FF"+(.@DCs+1)+".^000000 "+getguildname(.@gid[.@DCs])+" : ^FF0000"+.@kill[.@DCs]+"^000000 Death(s)"; } close; end; } prontera,160,203,4 script PVP Ladder#p1 837,{ query_sql "SELECT `char`.char_id,`char`.`name`,char_reg_num.`value` FROM char_reg_num LEFT JOIN `char` ON char_reg_num.char_id=`char`.char_id WHERE char_reg_num.key='kKILL' ORDER BY CAST(`char_reg_num`.`value` AS UNSIGNED) DESC LIMIT 5", .@char_id, .@name$, .@killcount; mes "[ ^00568A Player Kill Ranking ^000000 ]"; mes " "; for( set .@KCs,0; .@KCs<=4; set .@KCs,.@KCs+1 ){ mes "^0000FF"+(.@KCs+1)+".^000000 "+.@name$[.@KCs]+" : ^FF0000"+.@killcount[.@KCs]+"^000000 Kill(s)"; } if(!$deathcounter) end; else next; query_sql "SELECT `char`.char_id,`char`.`name`,char_reg_num.`value` FROM char_reg_num LEFT JOIN `char` ON char_reg_num.char_id=`char`.char_id WHERE char_reg_num.key='kDEAD' ORDER BY CAST(`char_reg_num`.`value` AS UNSIGNED) DESC LIMIT 5", .@char_id, .@name$, .@deathcount; mes "[ ^00568A Player Death Ranking ^000000 ]"; mes " "; for( set .@DCs,0; .@DCs<=4; set .@DCs,.@DCs+1 ){ mes "^0000FF"+(.@DCs+1)+".^000000 "+.@name$[.@DCs]+" : ^FF0000"+.@deathcount[.@DCs]+"^000000 Death(s)"; } close; end; }
-
yes sir. it works. much appreciated! thanks for helping and I learned stuff while asking you these questions.
-
ok thank you very much. I will try it. *EDIT* unfortunately it doesnt work. ill try to work around it. thanks again.
-
I see, thanks. so we'll just edit the refine ticket. thank you kind sir. first, I wanna apologize for troubling you so much and second I wanna apologize for double posting. but this is my last question for this matter. for example, I have a +4 item then I have a +8 refine ticket. we want the refiner to reject the +8 ticket and look for +5 refine ticket before he refines the item to +5. what code do I have to put in? (btw, we have separate tickets for weapons and for armors) again, thank you for your help and Im learning bit by bit with your advises. (im still learning things like !.@bArmorUp,@menu$+getitemname. you know the variables set by ragnarok)
-
thank you very much. I really appreciate the comments so I understand the code better. and here is our current script. it checks the level of the refine ticket of the player (for example +6 refine ticket or +9 refine ticket) but as I said it refines the item directly with the level of the player's refine ticket. can you please check if what's wrong here? thanks again yuno,177,188,3 script Refine Master 851,{ disable_items; if (countitem(6238) || countitem(6228) || countitem(6229) || countitem(6230) || countitem(6231) || countitem(6456)) set .@bWeaponUp,1; if (countitem(6239) || countitem(6232) || countitem(6233) || countitem(6234) || countitem(6235) || countitem(6457)) set .@bArmorUp,1; if (!.@bWeaponUp && !.@bArmorUp) { mes "[Refine Master]"; mes "Hello!"; mes "What's up?"; mes "I'm a specialist"; mes "for refining items,"; mes "but I don't work anymore."; next; switch(select("I'll go on my way.:Hmm... this makes me curious.")) { case 1: mes "[Refine Master]"; mes "Take care, adventurer."; close; case 2: mes "[Refine Master]"; mes "Actually, I sometimes provide refine services for adventurers with a ^006400Refine Ticket^000000..."; mes "Bye bye~!"; close; } } emotion e_gasp; mes "[Refine Master]"; mes "Greetings!"; mes "I can refine an item up to the ^006400same level as your ticket^000000."; mes "You don't have to worry! There's no chance of breaking your item."; next; if(select("I'll come back later.:Refine item with ticket.") == 1) { mes "[Refine Master]"; mes "Okay."; mes "You can come again later."; close; } mes "[Refine Master]"; mes "Which equipment would you like to refine?"; next; setarray .@position$[1],"Head upper","Armor","Left hand","Right hand","Robe","Shoes","Accessory 1","Accessory 2","Head middle","Head lower"; set .@menu$,""; for(set .@i,1; .@i<=10; set .@i,.@i+1) set .@menu$, .@menu$+((getequipisequiped(.@i))?getequipname(.@i):.@position$[.@i]+"- [Empty]")+":"; set .@part, select(.@menu$); if (!getequipisequiped(.@part)) { mes "[Refine Master]"; mes "You have to equip the item you want to refine."; close; } if (!getequipisenableref(.@part)) { emotion e_otl; mes "[Refine Master]"; mes "Oh, I'm sorry."; mes "This item is impossible to refine."; close; } switch(getequipweaponlv(.@part)) { default: case 0: setarray .@tickets[0],6457,6235,6234,6233,6232,6239; setarray .@levels[0],5,6,7,8,9,11; set .@type$,"Armor"; set .@check,.@bArmorUp; break; case 1: case 2: case 3: case 4: setarray .@tickets[0],6456,6231,6230,6229,6228,6238; setarray .@levels[0],5,6,7,8,9,11; set .@type$,"Weapon"; set .@check,.@bWeaponUp; break; } if (!.@check) { emotion e_dots; mes "[Refine Master]"; mes "If you want to refine this ^006400"+.@type$+"^000000, please come along with ^006400"+.@type$+" Refine Ticket^000000."; mes "See you later!"; close; } mes "[Refine Master]"; mes "Please choose which ^006400"+.@type$+" Refine Ticket^000000 you want to use."; next; set .@menu$,""; for(set .@i,0; .@i<getarraysize(.@tickets); set .@i,.@i+1) set .@menu$, .@menu$+getitemname(.@tickets[.@i])+":"; set .@select, select(.@menu$)-1; set .@ticket_lv, .@levels[.@select]; set .@ticket_id, .@tickets[.@select]; if (countitem(.@ticket_id) == 0) { emotion e_what; mes "[Refine Master]"; mes getitemname(.@ticket_id)+" is not in your inventory. Did you put it in your storage?"; mes "Please check again."; mes "See you later!"; close; } if (getequiprefinerycnt(.@part) >= .@ticket_lv) { emotion e_swt2; mes "[Refine Master]"; mes "^8B4513This item is already refined as much as your deed.^000000"; mes "Please come along with an item refined less than your ticket."; close; } mes "[Refine Master]"; mes "I'm going to refine ^006400"+getequipname(.@part)+"^8B4513 up to the +"+.@ticket_lv+" level^000000 with ^006400"+getitemname(.@ticket_id)+"^000000."; mes "May I proceed?"; next; if(select("No.:Yes.") == 1) { emotion e_dots; mes "[Refine Master]"; mes "Oh, you changed your mind."; mes "Ok."; mes "You can come back later."; close; } mes "[Refine Master]"; mes "Great."; mes "As you wish!"; mes "I have my own special way to refine..."; mes ".......ka boom!"; specialeffect EF_SUI_EXPLOSION; if (countitem(.@ticket_id)) delitem .@ticket_id,1; else { next; mes "Error!"; mes "Please report this."; close; } successrefitem .@part, .@ticket_lv - getequiprefinerycnt(.@part); next; emotion e_ho; mes "[Refine Master]"; mes "Alright, here it is~"; mes "Well, ^0000FF"+strcharinfo(0)+"^000000!"; mes "Congratulations on your shining "+.@type$+"."; mes "You look GREAT!"; mes "Farewell~!"; close; }
-
Hi. I just wanna know if you can help me with this. we got a refiner that needs a certain item before he can refine. (for us its refine ticket) our refiner gets the refine ticket (for example its safe to +9 refine ticket) and it refines the item up to +9. for example the item is +2 and you used our refiner, he will make it +9 we want the refiner to refine an item only 1 level higher (from my example above, if the item is +2 and the player used safe to +9 refine ticket, he will only get the item to +3) im sorry but im fairly new to RO scripts. thanks in advance and more power =)