Eviles 179 Report post Posted July 30, 2018 (edited) System Name: Admiral Cloak - Addon Credits: @KONG, for redirection on attribute modification; @Satan, creation and release po Introduction: I've made this script for a server, decided to release it, maybe will be useful for you. Admiral Cloak is new equipment released by Tales of Pirates II. When equipped it provides player attributes bonuses and also a nice glow on character according to it's level. When unsealed it has no stats and with a power of an injection you can enchant it to add attributes until it reach +5 of any of these: str, agi, con, acc, spr. Change-logs: - Release of scripts v1.0 (30/07/2018) - Added player attribute increment: function State_AC_Add(Player, StateLv) has been modified (31/07/2018) Setup: - Load this lua code using dofile() - ItemInfo line on attribute value must set 0,0 where the 1st value = stat that item will receive when created and 2nd value = max attribute item can reach - Paste codes inside function PIO_Effect_Cloak() at your cha_timer or hook as you like it - Easy configuration within tables - Enchant rates configurable on Cloak.upRate = {}, value = percentage - Cape effect configurable on Cloak.race = {}, value = skilleff line id - Glow Level 1-2 configurable on Cloak.eff01 = {}, value = skilleff line id - Glow Level 3-4 configurable on Cloak.eff02 = {}, value = skilleff line id - Glow Level 5 configurable on Cloak.eff03 = {}, value = skilleff line id - Put the following codes on AttrCalculate.lua, function Creat_Item() after local Num = 0 : --Admiral Cloak if item_event == 88 then for i = ITEMATTR_VAL_STR, ITEMATTR_VAL_STA do Add_Item_Attr(i, 0) end end Edited July 31, 2018 by Satan Change-logs 2 2 Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted August 21, 2018 @Satan can you share all other missing stuff? like iteminfo and others? i doesn't work with the ones im using, also do this have a cha_timer? coz it isn't in file Quote Share this post Link to post Share on other sites
iZae 55 Report post Posted August 21, 2018 On 7/30/2018 at 7:47 PM, Satan said: Paste codes inside function PIO_Effect_Cloak() at your cha_timer or hook as you like it Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted August 21, 2018 56 minutes ago, iZae said: I tried it, everything works fine like lvling it and unsealing expect it wont gives attributes and glows Quote Share this post Link to post Share on other sites
Eviles 179 Report post Posted August 30, 2018 The addon quite simple to reading, if you patiently and can speak english u can read it as like a normal text. Here a brief introduction which may help you out.. Quote Table 0 - Cloak Race: Cape effect(skilleff line id) Table 1 - Cloak Eff01: Glow to character according to cloak Lv(skilleff line id) Table 2 - Cloak Eff02: Glow to character according to cloak Lv(skilleff line id) Table 3 - Cloak Eff03: Glow to character according to cloak Lv(skilleff line id) Note¹: Cloak Race skilleff line must have State_AC_Add, State_AC_Rem; Note²: cha_timer function is PIO_Effect_Cloak(Player); 1 Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted September 17, 2018 @Satan This erros keep spamming my lua_err.txt, i followed the guide and it worked fine to unseal/add attributes it only doesn't increase stats and doesn't show glows, i added PIO_Effect_Cloak(Player) at cha_timer aswell.. Quote Share this post Link to post Share on other sites
Eviles 179 Report post Posted September 17, 2018 @Rinor You probably called PIO_Effect_Cloak() wrong, which mean that probably the param "Player" not being called correct. Which will result in that error that u receiving, since capeEff is declared on table at the top of script. Quote Share this post Link to post Share on other sites
Rinor 59 Report post Posted September 18, 2018 (edited) 16 hours ago, Satan said: @Rinor You probably called PIO_Effect_Cloak() wrong, which mean that probably the param "Player" not being called correct. Which will result in that error that u receiving, since capeEff is declared on table at the top of script. how to call it then, i used it at cha_timer can i change "Player" to another name? Edited September 18, 2018 by Rinor Quote Share this post Link to post Share on other sites
Eviles 179 Report post Posted September 18, 2018 cha_timer doesn't use "Player" as param. It called "role" by default.. You can understand it easy if u take 2 minutes of ur time reading something instead copy-paste. 2 Quote Share this post Link to post Share on other sites