Jump to content

mawjustin

Members
  • Posts

    121
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by mawjustin

  1. Hi Team, May I ask what error this is and how to fix it?
  2. I suggest you create a script using OnPCLoginEvent: just to make sure that all will be deleted.
  3. I commented that temporarily. and added deletion of SC_BOSSMAPINFO every login.
  4. Hi Team, Is there a way to stop gepard from detecting @autoattack as bot? https://rathena.org/board/topic/119441-compile-error-autoattack/ Thanks. @Functor may I ask for assistance regarding this matter.
  5. may I ask how will I do this? 61500:61500,{ if (isequipped(61500) <=10) { bonus bStr,1000; } } ? because 61500 can be inserted into non slotted slot 4 item only. and can be slotted to all general equipment .
  6. what if 1 type of card can be equipped in multiple items? example both poring cards can be equipped in upper,middle, and lower headgear? it will duplicate the effects of isequippedcnt()? Hi Team, May I ask why Is the stats not adding to the player? - script ScriptComboCaller -1,{ OnPCStatCalcEvent: if(getequipcardid (EQI_HEAD_TOP,3) == 61500 || getequipcardid (EQI_HEAD_MID,3) == 61500 || getequipcardid (EQI_HEAD_LOW,3) == 61500 || getequipcardid (EQI_ARMOR,3) == 61500 || getequipcardid (EQI_HAND_R,3) == 61500 || getequipcardid (EQI_HAND_L,3) == 61500 || getequipcardid (EQI_GARMENT,3) == 61500 || getequipcardid (EQI_SHOES,3) == 61500 || getequipcardid (EQI_ACC_L,3) == 61500 || getequipcardid (EQI_ACC_R,3) == 61500 ) { callfunc ("Generalis_Arvis"); } if(getequipcardid (EQI_HEAD_TOP,3) == 61501 || getequipcardid (EQI_HEAD_MID,3) == 61501 || getequipcardid (EQI_HEAD_LOW,3) == 61501 || getequipcardid (EQI_ARMOR,3) == 61501 || getequipcardid (EQI_HAND_R,3) == 61501 || getequipcardid (EQI_HAND_L,3) == 61501 || getequipcardid (EQI_GARMENT,3) == 61501 || getequipcardid (EQI_SHOES,3) == 61501 || getequipcardid (EQI_ACC_L,3) == 61501 || getequipcardid (EQI_ACC_R,3) == 61501 ) { callfunc ("Generalis_Mercator"); } } //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// function script Generalis_Arvis { sleep2 10; OnPCStatCalcEvent: setarray .setcomboarray[0],61500; set .@size,getarraysize( .setcomboarray ); .itmCnt = 0; for (.@i = 0;.@i < .@size;.@i++) { if(getequipcardid (EQI_HEAD_TOP,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_MID,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_LOW,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ARMOR,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_GARMENT,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_SHOES,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } } mes "Generalis_Arvis"+ .itmCnt; if (.itmCnt > 10 ) { dispbottom "You have more than 10 parts equipped."; } else { if(.itmCnt >= 2) { bonus bStr,5; } if(.itmCnt >= 3) { bonus bMaxSPrate,5; } if(.itmCnt >= 4) { bonus bMaxHPrate,5; } if(.itmCnt >= 5) { bonus bVariableCastrate,-5; } if(.itmCnt >= 6) { bonus bDelayRate,5; } if(.itmCnt >= 7) { bonus2 bIgnoreDefClassRate,Class_All,5; } if(.itmCnt >= 8) { bonus bAtkRate,5; } return; } } //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// function script Generalis_Mercator { sleep2 10; OnPCStatCalcEvent: setarray .setcomboarray[0],61501; set .@size,getarraysize( .setcomboarray ); .itmCnt = 0; for (.@i = 0;.@i < .@size;.@i++) { if(getequipcardid (EQI_HEAD_TOP,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_MID,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_LOW,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ARMOR,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_GARMENT,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_SHOES,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } } mes "Generalis_Mercator"+ .itmCnt; if (.itmCnt > 10 ) { dispbottom "You have more than 10 parts equipped."; } else { if(.itmCnt >= 2) { bonus bVit,5; } if(.itmCnt >= 3) { bonus bMaxSPrate,5; } if(.itmCnt >= 4) { bonus bMaxHPrate,5; } if(.itmCnt >= 5) { bonus bVariableCastrate,-5; } if(.itmCnt >= 6) { bonus bDelayRate,5; } if(.itmCnt >= 7) { bonus2 bSubEle,Ele_All,5; } if(.itmCnt >= 8) { bonus bMaxHPrate,5; } return; } } Output shows both, but stats is not adding into the player. May I ask for assistance in where did I go wrong here?
  7. Is there no other way from this? I'm avoiding doing it like that because I have around 60+ scripts like this and it might overload the server ?
  8. Hi, is there a way for this to stop looping? I mean to only display 1 value and not repeat it multiple times? Hi Team, How do we end loops? I'm trying to get the getitemname(.@rental[.@i]); but I want it to only display a single set, and not loop again and again. How can we display only a single set of result, and not multiple results? I have etc. item with the same script called. Basically my concern is stopping for loop to affect other parts of the code. function script Aqua_Set { setarray .@rental[0],61500,61501,61502,61503,61504; .@itmCnt = 0; for (.@i = 0; .@i < getarraysize(.@rental); .@i++) { if (countitem(.@rental[.@i])) { .@itmCnt++; } } if (2 < .@itmCnt) { mes "You can have a maximum of two out of the following list:"; for (.@i = 0; .@i < getarraysize(.@rental); .@i++) { mes "" + getitemname(.@rental[.@i]) + ""; } close; } } This is the screenshot of the result of the code. This is in etc. Thank you. Thanks, I fixed it, I called the function multiple times in the item_db, that's what's causing the loop. I converted it into a script instead. Hi Team, Is there a way to do item combo like this? instead of using item_combo_db.txt, we will create a script, or function that will count the number of parts the cards are equipped, and each part will give a different combo stats? Example: 2 Card Parts Equipped = STR + 3 3 Card Parts Equipped = INT + 5 4 Card Parts Equipped = DEX + 10 .. .. .. and so on. Thanks in advance guys. Hi guys, may I ask why am I receiving this error? I'm calling @MagicaeVentus from a function in combo. This is the code: //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// //////////////////////////////////////////////////////// function script Magicae_Set_Ventus { sleep2 10; setarray .setcomboarray[0],61500; setarray .setcombotext$[0],"INT +5","Maximum SP +5%","Maximum HP +5%","Wind Matk +5%","Wind Resist +5%","Ignore Mdef +10%","MATK. +10%"; // use @MagicaeVentus to check combo. bindatcmd "MagicaeVentus",strnpcinfo(3)+"::OnOrbCheck",0,60; set .@size,getarraysize( .setcomboarray ); .itmCnt = 0; for (.@i = 0; .@i < .@size; .@i++) { if(getequipcardid (EQI_HEAD_TOP,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_MID,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HEAD_LOW,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ARMOR,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_HAND_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_GARMENT,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_SHOES,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_L,3) == .setcomboarray[.@i] ) { .itmCnt++; } if(getequipcardid (EQI_ACC_R,3) == .setcomboarray[.@i] ) { .itmCnt++; } } mes .itmCnt; if (.itmCnt > 10 ) { dispbottom "You have more than 10 parts equipped."; } else { if(.itmCnt >= 2) { bonus bInt,5; } if(.itmCnt >= 3) { bonus bMaxSPrate,5; } if(.itmCnt >= 4) { bonus bMaxHPrate,5; } if(.itmCnt >= 5) { bonus2 bAddEle,Ele_Wind,5; } if(.itmCnt >= 6) { bonus2 bSubEle,Ele_Wind,5; } if(.itmCnt >= 7) { bonus2 bIgnoreMdefClassRate,Class_All,10; } if(.itmCnt >= 8) { bonus bMatkRate,10; } end; } OnOrbCheck: .itmCntTotal = 0; mes "^0000FFMagicae Ventus Set^000000: "; set .@size,getarraysize( .setcomboarray ); .itmCntTotal= 0; for (.@i = 0; .@i < .@size; .@i++) { if(getequipcardid (EQI_HEAD_TOP,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_HEAD_TOP) + " - [" + getitemname(getequipcardid (EQI_HEAD_TOP,3)) + "]"; } if(getequipcardid (EQI_HEAD_MID,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_HEAD_MID) + " - [" + getitemname(getequipcardid (EQI_HEAD_MID,3)) + "]"; } if(getequipcardid (EQI_HEAD_LOW,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_HEAD_LOW) + " - [" + getitemname(getequipcardid (EQI_HEAD_LOW,3)) + "]"; } if(getequipcardid (EQI_ARMOR,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_ARMOR) + " - [" + getitemname(getequipcardid (EQI_ARMOR,3)) + "]"; } if(getequipcardid (EQI_HAND_R,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_HAND_R) + " - [" + getitemname(getequipcardid (EQI_HAND_R,3)) + "]"; } if(getequipcardid (EQI_HAND_L,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_HAND_L) + " - [" + getitemname(getequipcardid (EQI_HAND_L,3)) + "]"; } if(getequipcardid (EQI_GARMENT,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_GARMENT) + " - [" + getitemname(getequipcardid (EQI_GARMENT,3)) + "]"; } if(getequipcardid (EQI_SHOES,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_SHOES) + " - [" + getitemname(getequipcardid (EQI_SHOES,3)) + "]"; } if(getequipcardid (EQI_ACC_L,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_ACC_L) + " - [" + getitemname(getequipcardid (EQI_ACC_L,3)) + "]"; } if(getequipcardid (EQI_ACC_R,3) == .setcomboarray[.@i]) { .itmCntTotal++; mes F_getpositionname(EQI_ACC_R) + " - [" + getitemname(getequipcardid (EQI_ACC_R,3)) + "]"; } else { } } mes " "; mes "Set Effect: [^00FF00Active^000000 : ^FF0000Inactive^000000] "; for (.@i = 0; .@i < getarraysize(.setcombotext$); .@i++) { .itmCntTotal--; if (.itmCntTotal > 0) { mes "^00FF00" + .setcombotext$[.@i] + "^000000"; } else { mes "^FF0000" + .setcombotext$[.@i] + "^000000"; } } mes " "; mes "^8b0000Note: Magicae Soul can be stacked with other Soul Sets.^000000"; close; end; }
  9. Hi Team, May I ask for assistance regarding this matter? Is there a way for this script to display only one value? I understand that it loops because of for loop value added in .@itmCnt++; but is there a way to display only 1 value of this loop stored value? function script Aqua_Set { getinventorylist; setarray .@rental[0],61500,61501,61502,61503,61504; .@itmCnt = 0; for (.@i = 0; .@i < getarraysize(.@rental); .@i++) { if (countitem(.@rental[.@i]) == 1) { .@itmCnt++; } } for(set .@i,0; .@i < @inventorylist_count; set .@i,.@i+1){ for(set .@ii,0; .@ii < getarraysize(.@rental); set .@ii,.@ii + 1){ if(@inventorylist_id[.@i] == .@rental[.@ii] && countitem(.@rental[.@ii]) == 1) { set .@itemCount,.@itemCount + 1; } } } if (.@itmCnt >= 2) { // this is the part that I want to fix, if possible to only display 1 loop value. mes .@itmCnt; end; } } I'm tryin to make an Etc. or charm type of items that depend on number of parts available, it must only read unique id, any duplicate in the inventory will render that part of the combo unusable, and will not add any stats. this is the result in my end.
  10. Hi Team, May I ask if this is possible without crashing the server? I tried putting it into a function, but it loops into infinity and crashes my server. Is there a way to add specialeffect2 on etc. items when you have them in your inventory? I'm using this as reference :
  11. put this in your npc script, I suggest you study basic rathena scripting first this is coded for manuk, so yes. if( getarg(0) == 2 ) { undisguise; if( strcharinfo(3) == "manuk" ) warp "SavePoint",0,0; end; } else if( strcharinfo(3) == "manuk" && getequipid(8) == 6010 && getequipid(6) == 5009 ) {
  12. no other scr mod for this?
  13. Hi Team, Is there a way for us to cap MDEF and DEF separately without using conf file? I would like to cap MDEF at 50, and DEF at 80. Thank you!
  14. Just duplicate else if( .@r >= 700 && .@r < 990 ) getitem 757,1;
  15. Thank you, found a guide regarding makeitem. https://rathena.org/board/topic/84778-makeitem-4x4-cell-on-monster-death/
  16. any fix on this? are we installing it right?
  17. Is this possible? for example, I have a custom monster summoned, when that monster dies it will trigger a command like @itemrain, and it will shower items within its perimeters.
  18. Is it possible to do this? Example. I have a headgear [43000], and the combo effect will be +5% demi human damage if any of the following range of lower [46000-46011] and middle [45000-45011] headgear is equipped. Basically the description is Thanks.
  19. can you give me a guide on how you did it? yeah, my Convex Mirror is not working properly right now, specially with MVP with similar name (LHZ)
  20. thank you.. it will be painful to do modifications
  21. Hi Team, may I ask for your help? I'm following this script, but unable to complete it, I need to add the cell distance between party killer and other party members, only those within 15 cells can get the reward in the map. I'm trying to combine these scripts. From here: From here: From here: This what I got so far, I am unable to do the distance from killer and party members. OnNPCKillEvent: sleep2 500; if (getgmlevel() >= .gm ) { end; } // If gm = event wont happen if ( getmonsterinfo( killedrid, MOB_MVPEXP )) { for (.@aaa = 0; .@aaa < getarraysize(.t_mvphunt_maps$); .@aaa++) { if ( strcharinfo(3) == .t_mvphunt_maps$[.@aaa]) { if ( getcharid(1) ) { .@mapname$ = .t_mvphunt_maps$[.@aaa]; getpartymember getcharid(1), 1; getpartymember getcharid(1), 2; getmapxy(.@mapname$,.@mapx,.@mapy,BL_PC); for ( .@i = 0; .@i < $@partymembercount; .@i++ ) { if ( !isloggedin( $@partymemberaid[.@i], $@partymembercid[.@i] ) || // what happens if someone in the party member is offline =/ strcharinfo(3,$@partymembercid[.@i]) != .@mapname$ || // If the party member is not on the same map of the killer checkidle(rid2name($@partymemberaid[.@i])) > 5 ) // If player is idle for 30 seconds continue; set .@mvppointshunt,0; getitem .p_rwd[0], .p_rwd[1], $@partymemberaid[.@i]; getitem .p_rwd[2], .p_rwd[3], $@partymemberaid[.@i]; announce "[ System ] : Player ["+ strcharinfo(0) +"] of party ["+ strcharinfo(1) +"] has killed "+ getmonsterinfo( killedrid, MOB_NAME ) +" at "+ strcharinfo(3), bc_all,0xffb6c1; } } else { set .@mvppointshunt,0; getitem .s_rwd[0], .s_rwd[1]; getitem .s_rwd[2], .s_rwd[3]; announce "[ System ] : Player ["+ strcharinfo(0) +"] has killed "+ getmonsterinfo( killedrid, MOB_NAME ) +" alone at "+ strcharinfo(3), bc_all,0xffb6c1; } MVPHunts = MVPHunts+1; dispbottom "---------------------------------------------------"; dispbottom "You killed a total of "+MVPHunts+" MVP"+((MVPHunts == 1)?"":"s")+"."; dispbottom "---------------------------------------------------"; dispbottom "[BB]: MVP Killed!"; end; } } end; } }
×
×
  • Create New...