-
Posts
103 -
Joined
-
Last visited
Content Type
Profiles
Forums
Downloads
Jobs Available
Server Database
Third-Party Services
Top Guides
Store
Crowdfunding
Posts posted by mawjustin
-
-
-
-
30 minutes ago, Litro Endemic said:
element like fire, wind and water? if yes, there is no available script command for that, since element is script based not field member of item, you need to create indexes your self for it
I see, I guess I that's the only option for now.
-
Hi Team,
I tried checking on rathena document, but I am unable to find the following, I'm not sure if I am looking in the wrong files or data:
1. How to check Random Option Element either from 1-5?
2. How to check Armor Element?
3. How to check Card slotted element?
Thank you in advance. -
For IP, time_created, and redeem_time problems use this.
/* DROP TABLE IF EXISTS `reward_codes`; DROP TABLE IF EXISTS `reward_logs`; CREATE TABLE IF NOT EXISTS `reward_codes` ( `promo` VARCHAR(26) NOT NULL DEFAULT '', `nameid` INT(11) UNSIGNED NOT NULL DEFAULT '0', `item_name` VARCHAR(50) NOT NULL DEFAULT '', `amount` SMALLINT(6) UNSIGNED NOT NULL DEFAULT '0', `time_created` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, `limit` INT(10) UNSIGNED NOT NULL DEFAULT '0', `pool` INT(10) UNSIGNED NOT NULL DEFAULT '0', PRIMARY KEY (`promo`) ) ENGINE = MYISAM; CREATE TABLE IF NOT EXISTS `reward_logs` ( `account_id` int(11) unsigned NOT NULL default '0', `last_ip` BINARY( 15 ) NOT NULL, `code` VARCHAR( 26 ) NOT NULL, `redeem_time` DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, `claim` INT( 10 ) NOT NULL, PRIMARY KEY (`code`) ) ENGINE = MYISAM; */ -
12 hours ago, cook1e said:
Cap limit seems to be 25
https://github.com/rathena/rathena/blob/master/src/map/path.cpp#L87
Increase it.Thank you!
-
Hi Team,
May I ask what error this is and how to fix it?

-
4 hours ago, nobodyelse said:
i deleted row in sc_data for convex mirror buff it solve the problem. i thought it was the only problem i had
but i still got map-serv crash randomly that the log didn't even show the problem
can anyone help me?I suggest you create a script using OnPCLoginEvent: just to make sure that all will be deleted.
-
On 6/19/2021 at 2:24 AM, nobodyelse said:
I commented that temporarily. and added deletion of SC_BOSSMAPINFO every login.
-
On 6/18/2021 at 11:06 PM, Chaos92 said:
You can PM @Functor. He will give u some patch for it.
thank you. I'll pm now.
-
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. -
1 hour ago, Emistry said:
item_combo effect should be done at db/re/item_combo_db.txt
this way, you won't need to worry about same effect triggered multiple times.
isequipped(61500, 61501, 61502, 61503, 61504);using this would tell you how many items are currently equipped.
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
.
-
20 hours ago, mR L said:
if (isequippedcnt(cardID) > 2) { bonus bStr,3; }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?

-
16 hours ago, Start_ said:
Ummm you do this on item script right?
For ::OnXXX just call the main npc that contain every item script to call.
- script MawJustin ,{ OnSetChaosCheck: end; OnSetPowerfulCheck: end; }then call it on function MawJustin::OnSetChaosCheck instead of strcharinfo(3).
I will try this.
-
Just now, Start_ said:
Try change this function to npc script-based.
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
-
On 9/17/2013 at 3:29 PM, DeadlySilence said:
You want to check if the user has fewer than three of an array of items?
setarray .@rental[0],990,991,992,993; .@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 should be what you're looking for, then.
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([email protected][[email protected]]); 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 [email protected][0],61500,61501,61502,61503,61504; [email protected] = 0; for ([email protected] = 0; [email protected] < getarraysize([email protected]); [email protected]++) { if (countitem([email protected][[email protected]])) { [email protected]++; } } if (2 < [email protected]) { mes "You can have a maximum of two out of the following list:"; for ([email protected] = 0; [email protected] < getarraysize([email protected]); [email protected]++) { mes "" + getitemname([email protected][[email protected]]) + ""; } close; } }This is the screenshot of the result of the code. This is in etc.

Thank you.
On 6/4/2021 at 3:39 AM, Magnetix said:if (2 < [email protected]) { mes "You can have a maximum of two out of the following list:"; for ([email protected] = 0; [email protected] < getarraysize([email protected]); [email protected]++) { mes "" + getitemname([email protected][[email protected]]) + ""; } close; }It'll work. Have you tried checking the part where your script called Aqua_Set?
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; }
-
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 [email protected]++; 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.

-
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 :
-
15 hours ago, macmac88 said:
how do i put this on my test server?
i'm a newbie in scripting... does the script only work on manuk map?
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 ) {
-
On 5/22/2021 at 2:47 PM, BeWan said:
no other scr mod for this?
-
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!
-
Just duplicate
else if( .@r >= 700 && .@r < 990 ) getitem 757,1;
-
Thank you! beautiful theme!
-
9 minutes ago, Balfear said:
Yes, you can use makeitem command
https://github.com/rathena/rathena/blob/master/doc/script_commands.txt#L4863Thank you, found a guide regarding makeitem. https://rathena.org/board/topic/84778-makeitem-4x4-cell-on-monster-death/

Stopping Random Option Duplicates on Mob Drop
in Source Requests
Posted
Hi Team,
May I ask on how we can detect if the random option is already assigned in either 1st to 5th random option slot?
I'm trying to avoid duplicate random option on mob drops.
I've used this post of mine as reference, random option is working.
My problem now is I cannot stop the duplication of random option, the random option always ends up being duplicated on either 1st to 5th slot.
I'm using this line. What I would like to achieve is that if the code detects the same random option id on the 1st to 5th slot, it will either break it, or reroll and add another random option.
Random Option must be unique and does not have a duplicate on all slots.
Thank you.