Petey Pablo
New member
- Messages
- 224
- Points
- 0
- Emulator
Requesting script to disable equip costume if the player have donate headgears. Thank you!
Please do elaborate and supply more information about your request, thanks.Requesting script to disable equip costume if the player have donate headgears. Thank you!
If you equipped donate items like item id 2280 you cannot equip any item id of costume items. Because I want to view the original sprite.Please do elaborate and supply more information about your request, thanks.Requesting script to disable equip costume if the player have donate headgears. Thank you!
If you equipped donate items like item id 2280 you cannot equip any item id of costume items. Because I want to view the original sprite.Please do elaborate and supply more information about your request, thanks.Requesting script to disable equip costume if the player have donate headgears. Thank you!
Thank you very much!If you equipped donate items like item id 2280 you cannot equip any item id of costume items. Because I want to view the original sprite.Please do elaborate and supply more information about your request, thanks.Requesting script to disable equip costume if the player have donate headgears. Thank you!
How about this?
Full Script Link: http://upaste.me/9ba637711820fb425
Instructions:
1) Load this script:
// =============================
/* Disable costume equip: http://herc.ws/board/topic/13925-disable-costume-equip/
----------------------------
by: Legend
compatible w/: Hercules
----------------------------
Description:
* Allows you to disable wearing of costume items
while donate items were equipped.
----------------------------
comments:
* Please report to me if bugs were found:
Contact: http://herc.ws/board/user/5387-legend/
*/
// =============================
- script Request#7 FAKE_NPC,{
OnInit:
// Add all your donate item id here
setarray .c[0],2220,2280; // 2220 = hat || 2201 = sunglass || 2280 = sakkat
end;
OnCheckItem:
for (.@i = 0; .@i < getarraysize(.c); ++.@i){
if (isequipped(.c[.@i])){
++.@citem;
}
}
if (.@citem){
if (getequipisequiped(EQI_COSTUME_HEAD_TOP)) unequip EQI_COSTUME_HEAD_TOP;
if (getequipisequiped(EQI_COSTUME_HEAD_MID)) unequip EQI_COSTUME_HEAD_MID;
if (getequipisequiped(EQI_COSTUME_HEAD_LOW)) unequip EQI_COSTUME_HEAD_LOW;
if (getequipisequiped(EQI_COSTUME_GARMENT)) unequip EQI_COSTUME_GARMENT;
message strcharinfo(0), "You are not allowed to wear costume item while wearing donate equipment.";
}
end;
}
2) Insert this script to ALL of your costume items on itemdb.
IF you miss this one, it won't work.
Script: <"
doevent "Request#7::OnCheckItem";
">
It seems I can't found any way to simplify things, so i wrote this way.
Please report if bugs were found.
And please don't forget to modify ".c[0]" array, add all your donate items in there.
We use essential cookies to make this site work, and optional cookies to enhance your experience.