Famous Posted June 3, 2013 Group: Members Topic Count: 145 Topics Per Day: 0.03 Content Count: 455 Reputation: 3 Joined: 06/19/12 Last Seen: February 26, 2018 Share Posted June 3, 2013 (edited) prontera,150,180,4 script VIP system 100,{ callfunc "func_setviptick",10000; end; } function script func_setviptick { set .@time,gettimetick(2)+getarg(0); setviptick .@time; set #VIP_TICK,.@time; return; } I tested this vip system http://rathena.org/board/files/file/2869-vip-temporary-rasie-reel/ and the script is not working Edited June 3, 2013 by zhen Quote Link to comment Share on other sites More sharing options...
Jaburak Posted June 3, 2013 Group: Members Topic Count: 48 Topics Per Day: 0.01 Content Count: 1125 Reputation: 236 Joined: 07/30/12 Last Seen: April 13 Share Posted June 3, 2013 You need to download the source mod and patch it. Quote Link to comment Share on other sites More sharing options...
Famous Posted June 4, 2013 Group: Members Topic Count: 145 Topics Per Day: 0.03 Content Count: 455 Reputation: 3 Joined: 06/19/12 Last Seen: February 26, 2018 Author Share Posted June 4, 2013 I also patch it @@ -9828,3 +9848,39 @@ return 0; } + +//VIP system + +bool pc_isVIP(struct map_session_data *sd) +{ + if( !battle_config.vip_active ) + return false; + if( sd == NULL ) + return false; + if( sd->bl.type != BL_PC ) + return false; + if( sd->VIP_Tick <= 0 ) + return false; + return ( sd->VIP_Tick > (int)time(NULL) ); +} + +int pc_search_inventory2(struct map_session_data *sd,int item_id) +{ + int i; + nullpo_retr(-1, sd); + + ARR_FIND( 0, MAX_INVENTORY, i, sd->status.inventory[i].nameid == item_id && sd->status.inventory[i].card[0] == -17 && sd->status.inventory[i].card[1] == -19 && sd->status.inventory[i].card[2] == -37 && sd->status.inventory[i].card[3] == -43 && (sd->status.inventory[i].amount > 0 || item_id == 0) ); + return ( i < MAX_INVENTORY ) ? i : -1; +} + +int pc_delitem3(struct map_session_data *sd,int item_id) +{ + int i; + nullpo_retr(-1, sd); + if(sd==NULL) + return 0; + for( i=0; i<MAX_INVENTORY; i++) + if( sd->status.inventory[i].nameid == item_id && sd->status.inventory[i].card[0] == -17 && sd->status.inventory[i].card[1] == -19 && sd->status.inventory[i].card[2] == -37 && sd->status.inventory[i].card[3] == -43 ) + pc_delitem(sd, i, 1, 0, 1, LOG_TYPE_NONE); + return 0; +} I'm wondering what line should put this + pc_delitem(sd, i, 1, 0, 1, LOG_TYPE_NONE); + return 0; +} what is the next line after this? part? bump anyone? Quote Link to comment Share on other sites More sharing options...
Jaburak Posted June 4, 2013 Group: Members Topic Count: 48 Topics Per Day: 0.01 Content Count: 1125 Reputation: 236 Joined: 07/30/12 Last Seen: April 13 Share Posted June 4, 2013 Try this? // ------------------------------------------------------------------------------------------ // ------ Script Release // Title: Premium/ViP Services System // Author: Diconfrost VaNz - www.wipeoutgaming.info - [email protected] // Version: 2.0 // Special thanks to the following for helping me making this script // Jezu // Dastgr // clydelion // // Note: This is a character-based script. If you want to make this into Account-Based, just put "#" beside "prmm". // ------------------------------------------------------------------------------------------ prontera,155,181,5 script Clahador 757,{ mes "[^FF0000Clahador^000000]"; mes "Hello "+strcharinfo(0)+", I'm ^FF0000Clahador the butcher^000000."; mes "I will be of help if you need something."; next; mes "[^FF0000Clahador^000000]"; mes "Oh! you need help?"; mes "What kind of help do you need?"; next; menu "Newbie here",P_New,"I'm a ViP!",P_VIP,"Nevermind",P_NVM; P_New: mes "[^FF0000Clahador^000000]"; mes "Did you already claim your free items in the ^FF0000Freebies NPC^000000???"; menu "Yes!",F_Yes,"No!",F_No; F_No: mes "[^FF0000Clahador^000000]"; mes "You should get 'em!."; mes "It will help you on the start."; close; F_Yes: mes "[^FF0000Clahador^000000]"; mes "Haha, i hope you like those items."; next; mes "By the way, you can earn zennies through quests like going to daily quest, request board, and many more!"; mes "Did you know that you can have many zennies you want if you gonna hunt more rare items?"; mes "Try it!"; close; P_VIP: mes "[^FF0000Clahador^000000]"; mes "Oh you avail our ViP Ticket!"; mes "Thank you!"; next; mes "[^FF0000Clahador^000000]"; mes "Your Premium Service will expire after " + callfunc("Time2Str",prmm); mes "You should maximize it"; mes "Grind your skills and hunt now!"; close; P_NVM: mes "[^FF0000Clahador^000000]"; mes "Thank you!"; mes "Come Again!"; close; function script getPremium { set .@ticks, getarg(0); if (.@ticks <= 0) { debugmes "getPremium - tried to set a timer in the past"; end; } set prmm, (prmm > gettimetick(2)) ? prmm : gettimetick(2)) + .@ticks; doevent "login::OnPCLoginEvent"; return; } - script login -1,{ OnPCLoginEvent: if (prmm > gettimetick(2)) { dispbottom "Your Premium Service will expire after " + callfunc("Time2Str",premium); sc_start SC_EXPBOOST,(( prmm - gettimetick(2) ) * 1000 ),200; sc_start SC_JEXPBOOST,(( prmm - gettimetick(2) ) * 1000 ),200; sc_start SC_ITEMBOOST,(( prmm - gettimetick(2) ) * 1000 ),100; atcommand "@adjgroup 1 "+strcharinfo(0); deltimer strnpcinfo(3)+"::OnPCLoginEvent"; if ((prmm - gettimetick(2)) < 2147483) { addtimer (prmm - gettimetick(2)) *1000, strnpcinfo(3)+"::OnPCLoginEvent"; } else { addtimer 2147483000, strnpcinfo(3)+"::OnPCLoginEvent"; } } else if (prmm) { atcommand "@adjgroup 0 "+strcharinfo(0); sc_end SC_EXPBOOST; sc_end SC_JEXPBOOST; sc_end SC_ITEMBOOST; set prmm, 0; dispbottom "Premium Services has ended."; } end; } OnAtcommand: dispbottom "Your Premium Service will expire after " + callfunc("Time2Str",prmm); end; OnInit: bindatcmd "premium",strnpcinfo(3)+"::OnAtcommand"; end; } Quote Link to comment Share on other sites More sharing options...
Famous Posted June 7, 2013 Group: Members Topic Count: 145 Topics Per Day: 0.03 Content Count: 455 Reputation: 3 Joined: 06/19/12 Last Seen: February 26, 2018 Author Share Posted June 7, 2013 [Error]: Loading NPC file: npc/custom/Zhen/vipsytem.txt script error on npc/custom/Zhen/vipsytem.txt line 63 expect ';' or '{' at function syntax 58 : mes "[^FF0000Clahador^000000]"; 59 : mes "Thank you!"; 60 : mes "Come Again!"; 61 : close; 62 : * 63 : function script' 'getPremium { 64 : set .@ticks, getarg(0); 65 : if (.@ticks <= 0) { 66 : debugmes "getPremium - tried to set a timer in the past"; 67 : end; 68 : } Quote Link to comment Share on other sites More sharing options...
Emistry Posted June 7, 2013 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: Sunday at 05:32 PM Share Posted June 7, 2013 mes "Come Again!"; close; } // <-------------MISSING Quote Link to comment Share on other sites More sharing options...
Question
Famous
I tested this vip system http://rathena.org/board/files/file/2869-vip-temporary-rasie-reel/
and the script is not working
Edited by zhenLink to comment
Share on other sites
5 answers to this question
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.