Leaderboard
Popular Content
Showing content with the highest reputation on 01/21/23 in all areas
-
Try with this freya,218,220,6 script Max Level 4_LGTSCIENCE,{ set .@gm_level, 99; // GM level required to set the reward set .@maxbase, 175; set .@maxjob, 60; set .@defaultreward, 39997; setarray .@rewardablejobs[0], Job_Rune_Knight_T, Job_Genetic_T, Job_Guillotine_Cross_T, Job_Minstrel_T, Job_Mechanic_T, Job_Royal_Guard_T, Job_Wanderer_T, Job_Ranger_T, Job_Sura_T, Job_Arch_Bishop_T, Job_Shadow_Chaser_T, Job_Sorcerer_T, Job_Warlock_T, Job_Kagerou, Job_Oboro; Begin: mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Hello, " + ((getgmlevel() >= .@gm_level) ? "master! What do you want to do today?" : "are you here for your reward?"); next; switch(select(((getgmlevel() >= .@gm_level) ? "Set Reward:Restart Race" : ":") + ":YES Please!:What is the Reward?:Who was rewarded?:Cancel")) { case 1: goto SetReward; case 2: goto RestartRace; case 3: goto GetReward; case 4: goto ExplainRace; case 5: goto ShowRewarded; default: end; } SetReward: mes "[ ^FF7700Race to Max Level^000000 ]"; if ($reward == 0) set $reward, .@defaultreward; mes "The reward is " + getitemname($reward) + " (ID: " + $reward + ")."; mes "Do you want to change it?"; next; if (select("Yes:No") == 1) { mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Please enter the new reward item ID."; input .@rewardid; next; mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Set " + getitemname(.@rewardid) + " as the reward?"; if(select("Yes:No") == 1) { set $reward, .@rewardid; } } goto Begin; RestartRace: mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Are you sure you want to restart the race?"; next; if (select("Yes:No") == 1) { for (.@i = 0; .@i < getarraysize(.@rewardablejobs); .@i++) { set $rewarded$[.@rewardablejobs[.@i]], ""; } announce "The Race to Max Level has begun! Claim a reward once you reach " + .@maxbase + " base and job " + .@maxjob + " !!", bc_all; } goto Begin; GetReward: mes "Let's see... " + strcharinfo(0) + ", huh?"; set .@competitioner, 0; for (.@i = 0; .@i < getarraysize(.@rewardablejobs); .@i++) { if (Class == .@rewardablejobs[.@i]) { set .@competitioner, 1; if (BaseLevel < .@maxbase || JobLevel < .@maxjob) { mes "I'm sorry, but you still need to level a bit more."; } else if ($rewarded$[Class] == strcharinfo(0) || getd("$MaxLevel" + get_unique_id() + "") == 1) { mes "You have already claimed your reward."; } else if ($rewarded$[Class] != "") { mes "Too late!"; mes "The reward for " + jobname(Class) + " was already claimed by " + $rewarded$[Class] + "."; } else goto GiveReward; } } if (.@competitioner == 0) mes "You need to change your job."; close; GiveReward: set $rewarded$[Class], strcharinfo(0); next; mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Congratulations! You were the first " + jobname(Class) + " to reach " + .@maxbase + " base and " + .@maxjob + " class!"; getitem $reward, 1; setd "$MaxLevel" + get_unique_id() + "",1; announce strcharinfo(0) + " ~ " + jobname(Class) + " ~ Has Reached Max. Level and Received " + getitemname($reward) + "!", bc_all; close; ExplainRace: mes "[ ^FF7700Race to Max Level^000000 ]"; mes "Yes! When you reach the maximum level for your class, talk to me and you'll be rewarded with a special item."; next; goto Begin; ShowRewarded: mes "[ ^FF7700Race to Max Level^000000 ]"; for (.@i = 0; .@i < getarraysize(.@rewardablejobs); .@i++) { mes jobname(.@rewardablejobs[.@i]) + ": " + (($rewarded$[.@rewardablejobs[.@i]] != "") ? $rewarded$[.@rewardablejobs[.@i]] : "^ff0000Nobody^000000"); } next; goto Begin; OnInit: while (1) { showscript " Race to 175 Winners! "; sleep 1000; } end; } I recommend you to use the code boxes next time1 point
-
use this script create a new text file - script storage2 -1,{ OnInit: bindatcmd "storage2",strnpcinfo(3)+"::OnAtcommand"; end; OnAtcommand: openstorage2(1,STOR_MODE_GET|STOR_MODE_PUT); end; } change this part - script storage2 -1,{ openstorage2(1,STOR_MODE_GET|STOR_MODE_PUT); to this for 2nd storage - script storage3 -1,{ openstorage2(2,STOR_MODE_GET|STOR_MODE_PUT); and so on the last storage in the script is a VIP one so if your server doesnt have VIP enable you can just delete the lines for VIP1 point
-
in your conf/inter_server.yml put this Body: - ID: 0 Name: "Storage" Table: storage - ID: 1 Name: "VIP" Table: storage2 max: 300 - ID: 2 Name: "VIP2" Table: storage3 max: 300 - ID: 3 Name: "VIP3" Table: storage4 max: 300 on your database SQL put this -- -- Table structure for table `storage` -- CREATE TABLE IF NOT EXISTS `storage` ( `id` int(11) unsigned NOT NULL auto_increment, `account_id` int(11) unsigned NOT NULL default '0', `nameid` int(10) unsigned NOT NULL default '0', `amount` smallint(11) unsigned NOT NULL default '0', `equip` int(11) unsigned NOT NULL default '0', `identify` smallint(6) unsigned NOT NULL default '0', `refine` tinyint(3) unsigned NOT NULL default '0', `attribute` tinyint(4) unsigned NOT NULL default '0', `card0` int(10) unsigned NOT NULL default '0', `card1` int(10) unsigned NOT NULL default '0', `card2` int(10) unsigned NOT NULL default '0', `card3` int(10) unsigned NOT NULL default '0', `option_id0` smallint(5) NOT NULL default '0', `option_val0` smallint(5) NOT NULL default '0', `option_parm0` tinyint(3) NOT NULL default '0', `option_id1` smallint(5) NOT NULL default '0', `option_val1` smallint(5) NOT NULL default '0', `option_parm1` tinyint(3) NOT NULL default '0', `option_id2` smallint(5) NOT NULL default '0', `option_val2` smallint(5) NOT NULL default '0', `option_parm2` tinyint(3) NOT NULL default '0', `option_id3` smallint(5) NOT NULL default '0', `option_val3` smallint(5) NOT NULL default '0', `option_parm3` tinyint(3) NOT NULL default '0', `option_id4` smallint(5) NOT NULL default '0', `option_val4` smallint(5) NOT NULL default '0', `option_parm4` tinyint(3) NOT NULL default '0', `expire_time` int(11) unsigned NOT NULL default '0', `bound` tinyint(3) unsigned NOT NULL default '0', `unique_id` bigint(20) unsigned NOT NULL default '0', `enchantgrade` tinyint unsigned NOT NULL default '0', PRIMARY KEY (`id`), KEY `account_id` (`account_id`) ) ENGINE=MyISAM; change this line `storage` to same name as you indicated in inter_server.yml ex: `storage2 ( as shown on my inter_server.yml CREATE TABLE IF NOT EXISTS `storage` ( here is the script im using byako,143,144,4 script More Storage#prt 4_F_KAFRA4,{ mes "[ Kafra ]"; mes "Which storage do you want to open?"; next; switch(select("Normal Storage","Storage1","Storage2","VIP Storage2")) { case 1: mes "[ Kafra ]"; mes "Storage will be opened. Thank you"; close2; openstorage; break; case 2: mes "[ Kafra ]"; mes "Storage 1 will be opened"; close2; openstorage2(1,STOR_MODE_GET|STOR_MODE_PUT); break; case 3: mes "[ Kafra ]"; mes "Storage 1 will be opened"; close2; openstorage2(2,STOR_MODE_GET|STOR_MODE_PUT); break; case 4: mes "[ Kafra ]"; if (vip_status(1)) { .@mode = STOR_MODE_GET|STOR_MODE_PUT; mes "VIP will be opened. Thank you"; } else { .@mode = STOR_MODE_GET; mes "Seems you're no longer VIP anymore. You only can take the items."; } close2; openstorage2(3,.@mode); break; } end; } i hope this can help ? Credits to this guide1 point