Zell Posted September 17, 2019 Posted September 17, 2019 View File Fake Icon Stats This commands allow you to add fake icon stats. Right now the command does not clean the effect automatically after the time, cause who order this command want to be like this, so you can add sleep and remove the icon. Sample Script: prontera,150,150,5 Script FakeIcon 90,{ mes "[Fake Icon Stats]"; mes "Hey."; switch(select("Receive Fake Icon 1 with 5 seconds (display only)","Receive Icon 2 for 10 seconds (display only)","Disable Icon 1 and 2")) { case 1: fakeIcon(getcharid(0),1,5000,1); break; case 2: fakeIcon(getcharid(0),2,10000,1); break; case 3: fakeIcon(getcharid(0),1,0,0); fakeIcon(getcharid(0),2,0,0); break; } close; } Submitter Zell Submitted 09/17/2019 Category Source Modifications Video Content Author Zell 2 Quote
Zell Posted September 18, 2019 Author Posted September 18, 2019 1 hour ago, Eichi said: What is the use of this, exactly? You can add new icons in your Lua files for show player VIP time... Show woe duration, for Quests timers and what ever you want. Quote
Naruto Posted September 20, 2019 Posted September 20, 2019 (edited) On 9/18/2019 at 11:37 PM, Eichi said: What is the use of this, exactly? Tons of effects are linked to status icons like soul linker blue effect And convex mirror icon Edited September 20, 2019 by Naruto Quote
Badarosk0 Posted September 25, 2019 Posted September 25, 2019 Good work! The problem is that when time runs out it keeps counting negatively. @Zell Quote
Zell Posted September 25, 2019 Author Posted September 25, 2019 1 hour ago, Badarosk0 said: Good work! The problem is that when time runs out it keeps counting negatively. @Zell Quote
Gidz Cross Posted October 9, 2023 Posted October 9, 2023 (edited) What is the best way to remove the icon when the timer ends? Can this be done in src? Edited October 9, 2023 by Gidz Cross Quote
Louis T Steinhil Posted June 16, 2024 Posted June 16, 2024 (edited) On 10/10/2023 at 12:23 AM, Gidz Cross said: What is the best way to remove the icon when the timer ends? Can this be done in src? This is the fix for icon not going away. and i edited also the timer so it could handle set .@timer, vip_status(2) - gettimetick(2); it will be 86400 for 1 day. So for 5 seconds it should be 5 i believe. // Script.cpp +/* +* fakeIcon +* fakeIcon(CHAR_ID,ICON_ID,TIME,STATE) +*/ +BUILDIN_FUNC(fakeIcon) +{ + int16 icon = EFST_BLANK; + TBL_PC* sd = map_charid2sd(script_getnum(st, 2)); + FETCH(3, icon); + int time = 1000 * abs(script_getnum(st, 4)); + bool state = (script_getnum(st, 5) == 1); + + if (sd == NULL) + return SCRIPT_CMD_FAILURE; + + if (icon <= EFST_BLANK || icon >= EFST_MAX) + icon = EFST_BLANK; + + clif_status_change(&sd->bl, (enum efst_type)icon, state, time, 0, 0, 0); + + return SCRIPT_CMD_SUCCESS; +} BUILDIN_FUNC(addrid) // Script.cpp ++BUILDIN_DEF(fakeIcon,"iiii"), BUILDIN_DEF(goto,"l"), Edited June 16, 2024 by Louis T Steinhil 1 Quote
Gidz Cross Posted December 29, 2024 Posted December 29, 2024 On 6/16/2024 at 11:16 AM, Louis T Steinhil said: This is the fix for icon not going away. and i edited also the timer so it could handle set .@timer, vip_status(2) - gettimetick(2); it will be 86400 for 1 day. So for 5 seconds it should be 5 i believe. // Script.cpp +/* +* fakeIcon +* fakeIcon(CHAR_ID,ICON_ID,TIME,STATE) +*/ +BUILDIN_FUNC(fakeIcon) +{ + int16 icon = EFST_BLANK; + TBL_PC* sd = map_charid2sd(script_getnum(st, 2)); + FETCH(3, icon); + int time = 1000 * abs(script_getnum(st, 4)); + bool state = (script_getnum(st, 5) == 1); + + if (sd == NULL) + return SCRIPT_CMD_FAILURE; + + if (icon <= EFST_BLANK || icon >= EFST_MAX) + icon = EFST_BLANK; + + clif_status_change(&sd->bl, (enum efst_type)icon, state, time, 0, 0, 0); + + return SCRIPT_CMD_SUCCESS; +} BUILDIN_FUNC(addrid) // Script.cpp ++BUILDIN_DEF(fakeIcon,"iiii"), BUILDIN_DEF(goto,"l"), I haven't got notification that you quote me on this thread. Haha. Sorry about that. How do you apply the icon removal in zell's script? Quote prontera,150,150,5 Script FakeIcon 90,{ mes "[Fake Icon Stats]"; mes "Hey."; switch(select("Receive Fake Icon 1 with 5 seconds (display only)","Receive Icon 2 for 10 seconds (display only)","Disable Icon 1 and 2")) { case 1: fakeIcon(getcharid(0),1,5000,1); break; case 2: fakeIcon(getcharid(0),2,10000,1); break; case 3: fakeIcon(getcharid(0),1,0,0); fakeIcon(getcharid(0),2,0,0); break; } close; } Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.