Hello,
I need help to add "Once player enters the fishing map, they will be kicked out every three hours".
map,xxx,xxx,0 script Fishing Hole 844,{
//Fishing rod
set .@Rod,xxxx;
//Fishing Lure
set .@Lure,xxxx;
//Auto-Fish
set .@Auto,1;
//Auto-Fish on Fail
set .@AutoFail,1;
Fish:
.@weight = 100 * Weight / MaxWeight;
if (90 <= .@weight) {
mes "^FA2103You are currently at " + .@weight + " percent of your maximum weight.^000000";
end;
}
if (isequipped(.@Rod)) && (isequipped(.@Lure)){
specialeffect EF_BUBBLE,"Fishing Hole";
//soundeffect "fishingrod.wav",0;
dispbottom "[Fishing] Casting...";
set .@fcast,15;
if (isequipped(2550)) { //Fisher's Muffler
set .@fcast,.@fcast - 1;
}
if (isequipped(2443)) { //Fisher's Boots
set .@fcast,.@fcast - 1;
}
if (isequipped(2764)) { //Fishing Pole
set .@fcast,.@fcast - 3;
}
if (isequipped(2775)) { //Fishing Lure
set .@fcast,.@fcast - 2;
}
if (isequipped(5317)) { //head
set .@fcast,.@fcast - 2;
}
if (isequipped(5403)) { //mouth
set .@fcast,.@fcast - 2;
}
progressbar "ffffff",.@fcast;
if (rand(1,100) == 3){ // 3%
getitem 7227,5; // TCG 3% chance
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got x5 TCG",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12210,1; // BBG
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Bubble Gum",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12203,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Steamed Scorpion",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12202,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Steamed Tongue",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12204,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Dragon Breath Cocktail",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12205,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Hwergelmir's Tonic",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12206,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Cooked Nine Tail's Tails",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
else if (rand(1,100) == 3){ // 3%
getitem 12207,1; //
specialeffect2 EF_TEMP_OK;
//soundeffectall "success.wav",0,strcharinfo(3);
mapannounce strcharinfo(3),strcharinfo(0)+" Got 1x Stew Of Immortality",bc_map,"0xff77ff";
if(.@Auto==1){
goto Fish;}else{
end;}
}
if (rand(1,6) == 1) ||(rand(1,6) == 3) || (rand(1,6) == 6){
setarray .@Catch[0],1010,1011,984,985;// List of Junk/Other
set .@CatchRand,.@Catch[rand(getarraysize(.@Catch))];
getitem .@CatchRand,1;
}
else {
dispbottom "[Fishing] Nothing was caught...";
if(.@AutoFail == 1){
goto Fish;} else{
end;}
}
if (rand(1,100) == 1){ // 1%
setarray .@Rare[0],7179;
set .@RareCatch, .@Rare[rand(getarraysize(.@Rare))];
getitem .@RareCatch,1; //Reward
set #FISHINGPOINTS,#FISHINGPOINTS+1;
announce "[Fishing System]: "+strcharinfo(0)+" Got 1 "+getitemname(.@RareCatch)+".",0,0x33CC00;
}
if(.@Auto == 1){
goto Fish;} else{
end;}
}
else {
dispbottom "[Fishing] You need a Rod and Lure.";
end;
}
}
map,xxx,xxx,0 duplicate(Fishing Hole) Fishing Hole#fish2-1 844
//map,xxx,xxx,0 duplicate(Fishing Hole) Fishing Hole#fish2-2 844
//map,xxx,xxx,0 duplicate(Fishing Hole) Fishing Hole#fish2-3 844
// Dealer
map,xxx,xxx,6 shop Fish Dealer 958,xxx:xxxx,2775:xxxx,2443:xxxx,2550:xxxx
Many thanks.