Jump to content
  • 0

Domination script bugged


donkeyg

Question


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

//===== rAthena Script =======================================
//= Domination Event
//===== By: ==================================================
//= Leertaste
//===== Current Version: =====================================
//= 1.0a
//===== Compatible With: =====================================
//= Every eAthena or rAthena Version
//===== Description: =========================================
//= Automated Event where every click from every char
//= increases the Number by 1 (+1)
//= The winner is who increases the Number to the max. (for example 1000)
//===== Comments: ============================================
//= This Event is automated but can be started from InGame too
//= Price/Amount and Amount-to-click is also settable from InGame
//= Change (if(getgmlevel() > 60)) // 60 to the wished GM-Level for Setups
//============================================================
//===== Changelog: ===========================================
//= -1.0a - Addet Current Variables when changing Price/Amount
//=   - Addet Effects to Show Member which Npc is meant
//=   - Addet Ingame Menupoint (For Admin) to edit required manage GM-Level
//=   - Addet Auto protect from Input 0 (Amount/GM Level)
//=   - Changed NPC ID cause of annoying noise
//=   - Fixed Bug that comes through Npctalk (changed to Announce)
//=
//= -1.0  Finshed Scripting
//============================================================


alberta,195,141,5 script [Domination] 440,{


if ($@domination_start == 1) {
set .dom_click,.dom_click+1;
specialeffect2 4;
announce "Counter: ["+.dom_click+"]",bc_map|bc_blue;
if (.dom_click == $@domination_amount) {
announce "[Domination]: " + strcharinfo(0) + " is the winner!",bc_all;
set .dom_click,0;
set $@domination_start,0;
getitem $prize_id_dom, $prize_amount_dom;
end;
}
}else{


set .name$, "[Domination]";
set .menu$, "Times:Information:What's the Amount?:What's the Price?:Leave";
if(getgmlevel() > $GM_Dom-1) set .menu$, .menu$ + ":^008000Set Amount ^ff0000[GM]:^008000Set Price ^ff0000[GM]:^008000Start Event ^ff0000[GM]^000000";
if(getgmlevel() > 99) set .menu$, .menu$ + ":^008000Set GM Level ^ff0000[ADMIN]^000000";


mes .name$;
mes "What do you want?";
next;
h_menu:
switch(select(.menu$)) {
case 1:
mes .name$;
mes "^ff0000Domination^000000 starts each day at:";
mes "^00800014:30^000000, ^00800017:30^000000 and ^00800020:30^000000 o'clock.";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 2:
mes .name$;
mes "^ff0000Domination^000000";
mes "Is a game where you need";
mes "to click the Number up to:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "Every click (from everybody)";
mes "will increase the Number by 1";
next;
mes .name$;
mes "To win you will need to have";
mes "the last click to increase the";
mes "Number up to the set amount";
mes "(-- ^ff0000"+$@domination_amount+"^000000 --)";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 3:
mes .name$;
mes "The amount to click is:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 4:
mes .name$;
mes "The Price is:";
mes " -- ^ff0000"+$prize_amount_dom+" ^008000"+getitemname($prize_id_dom)+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 5:
mes .name$;
mes "Have a nice day.";
close;


case 6: // Setting the Amount to click
mes .name$;
mes "Enter the Amount which";
mes "is needed to reach:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
input $@domination_amount;
if ($@domination_amount == 0){
next;
mes .name$;
mes "I think it's not a good idea put";
mes "this to 0 because there will be no ending";
mes " -- ^ff0000Automatically set to 100^000000 --";
set $@domination_amount,100;
}
next;
mes .name$;
mes "The amount to click is now:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 7: // Setting the Price
mes .name$;
mes "Enter the Item ID of the Price:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$prize_id_dom+"^000000 --";
mes "(^008000"+getitemname($prize_id_dom)+"^000000)";
input $prize_id_dom;
next;
mes .name$;
mes "Now enter the Amount of items the winner will recieve:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$prize_amount_dom+"^000000 -- ^008000"+getitemname($prize_id_dom)+"^000000 --";
input $prize_amount_dom;
next;
mes .name$;
mes "The Price ID is: ^ff0000"+$prize_id_dom+"^000000";
mes "The Amount is: ^ff0000"+$prize_amount_dom+"^000000.";
mes " ";
mes " -- ^ff0000"+$prize_amount_dom+" ^008000"+getitemname($prize_id_dom)+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 8:
sleep2 100;
close2;
goto l_start;
end;


case 9:
mes .name$;
mes "Enter the required GM Level";
mes "to manage this Event.";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$GM_Dom+"^000000 --";
input $GM_Dom;
if ($GM_Dom == 0){
next;
mes .name$;
mes "I think it's not a good idea let";
mes "GM Level 0 manage this event.";
mes " -- ^ff0000Automatically set to 60^000000 --";
set $GM_Dom,60;
}
next;
mes .name$;
mes "GM Level = ^ff0000"+$GM_Dom+"^000000";
mes "can now manage this event.";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


OnClock0122:
OnClock0322:
OnClock0522:
OnClock0722:
OnClock0922:
OnClock1222:
OnClock1522:
OnClock1722:
OnClock1922:
OnClock2122:
OnClock2322:
l_start:
announce "[Domination]: Domination - Event starts in 1 Minute at Alberta @go alberta!",bc_all;
specialeffect 12, SELF;
sleep2 30000;
announce "[Domination]: We are going to start in 30 Seconds!",bc_all;
specialeffect 12, SELF;
sleep2 25000;
announce "[Domination]: Get Ready only 5 Seconds left!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 4!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 3!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 2!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 1!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "START! CLICK ME AS FAST AS YOU CAN!",bc_all;
set $@domination_start,1;
end;


}
}
}

help pls.. even normal player also can set the prizes... what happened?

Link to comment
Share on other sites

9 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  1479
  • Reputation:   172
  • Joined:  12/14/11
  • Last Seen:  

the way the scripter set $GM_Dom is just ******* (read: aladeen).

just put this on the beginning (below the script header) or the end (before the script end curly }):

OnInit:
set $GM_Dom, 60;

change the value, set it to sth. refer to groups.conf

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

the way the scripter set $GM_Dom is just ******* (read: aladeen).

just put this on the beginning (below the script header) or the end (before the script end curly }):

OnInit:
set $GM_Dom, 60;

change the value, set it to sth. refer to groups.conf

set .name$, "[Domination]";
set .menu$, "Times:Information:What's the Amount?:What's the Price?:Leave";
OnInit:
set $GM_Dom, 60;
if(getgmlevel() > $GM_Dom-1) set .menu$, .menu$ + ":^008000Set Amount ^ff0000[GM]:^008000Set Price ^ff0000[GM]:^008000Start Event ^ff0000[GM]^000000";
if(getgmlevel() > 99) set .menu$, .menu$ + ":^008000Set GM Level ^ff0000[ADMIN]^000000";

like this?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  1479
  • Reputation:   172
  • Joined:  12/14/11
  • Last Seen:  

no, like this:

prontera,x,y,d  script  name  504,{
OnInit:
set $GM_Dom, 60;
end;

<the rest of the script goes here>
end;
}

 

the way the scripter set $GM_Dom is just ******* (read: aladeen).

just put this on the beginning (below the script header) or the end (before the script end curly }):

OnInit:
set $GM_Dom, 60;

change the value, set it to sth. refer to groups.conf

set .name$, "[Domination]";
set .menu$, "Times:Information:What's the Amount?:What's the Price?:Leave";
OnInit:
set $GM_Dom, 60;
if(getgmlevel() > $GM_Dom-1) set .menu$, .menu$ + ":^008000Set Amount ^ff0000[GM]:^008000Set Price ^ff0000[GM]:^008000Start Event ^ff0000[GM]^000000";
if(getgmlevel() > 99) set .menu$, .menu$ + ":^008000Set GM Level ^ff0000[ADMIN]^000000";

like this?

 

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

//===== rAthena Script =======================================
//= Domination Event
//===== By: ==================================================
//= Leertaste
//===== Current Version: =====================================
//= 1.0a
//===== Compatible With: =====================================
//= Every eAthena or rAthena Version
//===== Description: =========================================
//= Automated Event where every click from every char
//= increases the Number by 1 (+1)
//= The winner is who increases the Number to the max. (for example 1000)
//===== Comments: ============================================
//= This Event is automated but can be started from InGame too
//= Price/Amount and Amount-to-click is also settable from InGame
//= Change (if(getgmlevel() > 60)) // 60 to the wished GM-Level for Setups
//============================================================
//===== Changelog: ===========================================
//= -1.0a - Addet Current Variables when changing Price/Amount
//=   - Addet Effects to Show Member which Npc is meant
//=   - Addet Ingame Menupoint (For Admin) to edit required manage GM-Level
//=   - Addet Auto protect from Input 0 (Amount/GM Level)
//=   - Changed NPC ID cause of annoying noise
//=   - Fixed Bug that comes through Npctalk (changed to Announce)
//=
//= -1.0  Finshed Scripting
//============================================================


alberta,195,141,5 script [Domination] 440,{


OnInit:
set $GM_Dom, 60;


if ($@domination_start == 1) {
set .dom_click,.dom_click+1;
specialeffect2 4;
announce "Counter: ["+.dom_click+"]",bc_map|bc_blue;
if (.dom_click == $@domination_amount) {
announce "[Domination]: " + strcharinfo(0) + " is the winner!",bc_all;
set .dom_click,0;
set $@domination_start,0;
getitem $prize_id_dom, $prize_amount_dom;
end;
}
}else{


set .name$, "[Domination]";
set .menu$, "Times:Information:What's the Amount?:What's the Price?:Leave";
if(getgmlevel() > $GM_Dom-1) set .menu$, .menu$ + ":^008000Set Amount ^ff0000[GM]:^008000Set Price ^ff0000[GM]:^008000Start Event ^ff0000[GM]^000000";
if(getgmlevel() > 99) set .menu$, .menu$ + ":^008000Set GM Level ^ff0000[ADMIN]^000000";


mes .name$;
mes "What do you want?";
next;
h_menu:
switch(select(.menu$)) {
case 1:
mes .name$;
mes "^ff0000Domination^000000 starts each day at:";
mes "^Every 2 ~ 3 o'clock";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 2:
mes .name$;
mes "^ff0000Domination^000000";
mes "Is a game where you need";
mes "to click the Number up to:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "Every click (from everybody)";
mes "will increase the Number by 1";
next;
mes .name$;
mes "To win you will need to have";
mes "the last click to increase the";
mes "Number up to the set amount";
mes "(-- ^ff0000"+$@domination_amount+"^000000 --)";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 3:
mes .name$;
mes "The amount to click is:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 4:
mes .name$;
mes "The Price is:";
mes " -- ^ff0000"+$prize_amount_dom+" ^008000"+getitemname($prize_id_dom)+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 5:
mes .name$;
mes "Have a nice day.";
close;


case 6: // Setting the Amount to click
mes .name$;
mes "Enter the Amount which";
mes "is needed to reach:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
input $@domination_amount;
if ($@domination_amount == 0){
next;
mes .name$;
mes "I think it's not a good idea put";
mes "this to 0 because there will be no ending";
mes " -- ^ff0000Automatically set to 100^000000 --";
set $@domination_amount,100;
}
next;
mes .name$;
mes "The amount to click is now:";
mes " -- ^ff0000"+$@domination_amount+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 7: // Setting the Price
mes .name$;
mes "Enter the Item ID of the Price:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$prize_id_dom+"^000000 --";
mes "(^008000"+getitemname($prize_id_dom)+"^000000)";
input $prize_id_dom;
next;
mes .name$;
mes "Now enter the Amount of items the winner will recieve:";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$prize_amount_dom+"^000000 -- ^008000"+getitemname($prize_id_dom)+"^000000 --";
input $prize_amount_dom;
next;
mes .name$;
mes "The Price ID is: ^ff0000"+$prize_id_dom+"^000000";
mes "The Amount is: ^ff0000"+$prize_amount_dom+"^000000.";
mes " ";
mes " -- ^ff0000"+$prize_amount_dom+" ^008000"+getitemname($prize_id_dom)+"^000000 --";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


case 8:
sleep2 100;
close2;
goto l_start;
end;


case 9:
mes .name$;
mes "Enter the required GM Level";
mes "to manage this Event.";
mes " ";
mes "Current is:";
mes " -- ^ff0000"+$GM_Dom+"^000000 --";
input $GM_Dom;
if ($GM_Dom == 0){
next;
mes .name$;
mes "I think it's not a good idea let";
mes "GM Level 0 manage this event.";
mes " -- ^ff0000Automatically set to 60^000000 --";
set $GM_Dom,60;
}
next;
mes .name$;
mes "GM Level = ^ff0000"+$GM_Dom+"^000000";
mes "can now manage this event.";
next;
mes .name$;
mes "What else?";
next;
goto h_menu;


OnClock0122:
OnClock0322:
OnClock0522:
OnClock0722:
OnClock0922:
OnClock1222:
OnClock1522:
OnClock1722:
OnClock1922:
OnClock2122:
OnClock2322:
l_start:
announce "[Domination]: Domination - Event starts in 1 Minute at Alberta @go alberta!",bc_all;
specialeffect 12, SELF;
sleep2 30000;
announce "[Domination]: We are going to start in 30 Seconds!",bc_all;
specialeffect 12, SELF;
sleep2 25000;
announce "[Domination]: Get Ready only 5 Seconds left!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 4!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 3!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 2!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "[Domination]: 1!",bc_all;
specialeffect 12, SELF;
sleep2 1000;
announce "START! CLICK ME AS FAST AS YOU CAN!",bc_all;
set $@domination_start,1;
end;
end;
}
}
}

like this bro?

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  1479
  • Reputation:   172
  • Joined:  12/14/11
  • Last Seen:  


OnInit:

set $GM_Dom, 60;

end;

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

OnInit:
set $GM_Dom, 60;
end;

its not working.. can u just gie me a complete script pls?=.=

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.00
  • Content Count:  1479
  • Reputation:   172
  • Joined:  12/14/11
  • Last Seen:  

no, not even downloading the script

 

what's with that =.=?

 

=.=

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

no, not even downloading the script

 

what's with that =.=?

 

=.=

it worsk fine. but my the event wont start automatically.. ..

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  344
  • Topics Per Day:  0.08
  • Content Count:  1060
  • Reputation:   1
  • Joined:  02/13/12
  • Last Seen:  

 bumppppppppppppp

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...