Jump to content
  • 0

WOE Script


Terenas

Question


  • Group:  Members
  • Topic Count:  1
  • Topics Per Day:  0.00
  • Content Count:  4
  • Reputation:   0
  • Joined:  11/11/12
  • Last Seen:  

I have error with this script, and it is not working. Can anyone see what is wrong?

prontera,146,197,5 script WoE Reward 1288,{
mes "^000088[Emperium]^000000";
mes "Greetings, adventurer!";
mes "Do you want to redeem your guild reward for last session War of Emperium?";
next;
mes "^000088[Emperium]^000000";
mes "Please select your castle.";
next;
if ( agitcheck() ) goto L_woeon;
menu
 "Neuschwanstein",L_aldeg_cas01,
 "Hohenschwangau",L_aldeg_cas02,
 "Nuenberg",L_aldeg_cas03,
// "Wuerzburg",L_aldeg_cas04,
// "Rothenburg",L_aldeg_cas05,
 "Repherion",L_gefg_cas01,
 "Eeyolbriggar",L_gefg_cas02,
 "Yesnelph",L_gefg_cas03,
 "Bergel",L_gefg_cas04,
// "Mersetzdeitz",L_gefg_cas05,
 "Bright Arbor",L_payg_cas01,
 "Scarlet Palace",L_payg_cas02,
 "Holy Shadow",L_payg_cas03,
 "Sacred Altar",L_payg_cas04,
// "Bamboo Grove Hill",L_payg_cas05,
 "Kriemhild",L_prtg_cas01,
 "Swanhild",L_prtg_cas02,
 "Fadhgridh",L_prtg_cas03,
 "Skoegul",L_prtg_cas04;
// "Gondul",L_prtg_cas05;
L_aldeg_cas01:
if ( getcastledata( "aldeg_cas01", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[1] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[1], 1;
close;
L_aldeg_cas02:
if ( getcastledata( "aldeg_cas02", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[2] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[2], 1;
close;
L_aldeg_cas03:
if ( getcastledata( "aldeg_cas03", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[3] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[3], 1;
close;
L_aldeg_cas04:
if ( getcastledata( "aldeg_cas04", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[4] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(7539,300) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 7539, 300;
set $castle_claimed[4], 1;
close;
L_aldeg_cas05:
if ( getcastledata( "aldeg_cas05", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[5] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
mes "receiving the reward for this castle";
getitem 7539, 300;
set $castle_claimed[5], 1;
close;L_gefg_cas01:
if ( getcastledata( "gefg_cas01", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[6] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[6], 1;
close;
L_gefg_cas02:
if ( getcastledata( "gefg_cas02", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[7] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[7], 1;
close;
L_gefg_cas03:
if ( getcastledata( "gefg_cas03", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[8] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[8], 1;
close;
L_gefg_cas04:
if ( getcastledata( "gefg_cas04", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[9] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[9], 1;
close;
L_gefg_cas05:
if ( getcastledata( "gefg_cas05", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[10] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 7539, 300;
set $castle_claimed[10], 1;
close;
L_payg_cas01:
if ( getcastledata( "payg_cas01", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[11] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[11], 1;
close;
L_payg_cas02:
if ( getcastledata( "payg_cas02", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[12] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[12], 1;
close;
L_payg_cas03:
if ( getcastledata( "payg_cas03", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[13] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[13], 1;
close;
L_payg_cas04:
if ( getcastledata( "payg_cas04", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[14] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[14], 1;
close;
L_payg_cas05:
if ( getcastledata( "payg_cas05", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[15] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
mes "receiving the reward for this castle";
getitem 7539, 300;
set $castle_claimed[15], 1;
close;L_prtg_cas01:
if ( getcastledata( "prtg_cas01", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[16] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "[Emperium]";
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[16], 1;
close;
L_prtg_cas02:
if ( getcastledata( "prtg_cas02", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[17] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[17], 1;
close;
L_prtg_cas03:
if ( getcastledata( "prtg_cas03", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[18] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "[Emperium]";
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[18], 1;
close;
L_prtg_cas04:
if ( getcastledata( "prtg_cas04", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[19] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 21069,100;
set $castle_claimed[19], 1;
close;
L_prtg_cas05:
if ( getcastledata( "prtg_cas05", 1) != getcharid(2) ) goto L_not_owner;
if ( $castle_claimed[20] ) goto L_claimed;
if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;
if ( checkweight(21069,100) == 0 ) goto L_CheckWeight;
mes "receiving the reward for this castle";
getitem 7539, 300;
set $castle_claimed[20], 1;
close;
L_woeon:
mes "^000088[Emperium]^000000";
mes "A war is currently in progress.";
mes "If your guild owned a castle ask your guild master to see me to claim the reward.";
close;
L_not_owner:
mes "^000088[Emperium]^000000";
mes "Your guild failed to take this castle.";
mes "If your guild owned a castle ask your guild master to claim reward from me.";
close;
L_claimed:
mes "^000088[Emperium]^000000";
mes "Your guild already received the reward for this castle.";
close;
L_not_gm:
mes "^000088[Emperium]^000000";
mes "Ask your guild master to see me.";
close;L_CheckWeight:
mes "Please check your weight!";
close;
//OnAgitEnd:
OnClock0000:
set $castle_claimed[1], 0; // everytime woe ends the variable resets
set $castle_claimed[2], 0;
set $castle_claimed[3], 0;
set $castle_claimed[4], 0;
set $castle_claimed[5], 0;
set $castle_claimed[6], 0;
set $castle_claimed[7], 0;
set $castle_claimed[8], 0;
set $castle_claimed[9], 0;
set $castle_claimed[10], 0;
set $castle_claimed[11], 0;
set $castle_claimed[12], 0;
set $castle_claimed[13], 0;
set $castle_claimed[14], 0;
set $castle_claimed[15], 0;
set $castle_claimed[16], 0;
set $castle_claimed[17], 0;
set $castle_claimed[18], 0;
set $castle_claimed[19], 0;
set $castle_claimed[20], 0;
end;
}

Edited by Terenas
codeboxed
Link to comment
Share on other sites

8 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  1
  • Topics Per Day:  0.00
  • Content Count:  4
  • Reputation:   0
  • Joined:  11/11/12
  • Last Seen:  

I prefer it if I can find out what is wrong with the script. It's for educational purpose. Server gives word undercores error

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  18
  • Topics Per Day:  0.00
  • Content Count:  2044
  • Reputation:   682
  • Joined:  10/09/12
  • Last Seen:  

@Euphy ...

this is one of the purpose I want to revive rAAC ....

currently our scripting community has been produced overly complicated script to solve a simple solution ...

@Terenas

I tested the script working fine in my test server

the only reason that I can think of is probably because you use 1288 as npc ID ? try change to 123

Server gives word undercores error
can show us some screenshot ?
Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  59
  • Reputation:   0
  • Joined:  12/13/12
  • Last Seen:  

I cant get it to work for my server.

I try clicking it nothing happen.

using r17013

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

It's no longer needed, really. I added a feature to auto-mail rewards to Guild Masters in v1.5 of my controller: trunk/npc/custom/woe_controller.txt

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  22
  • Topics Per Day:  0.01
  • Content Count:  59
  • Reputation:   0
  • Joined:  12/13/12
  • Last Seen:  

isit like this

setarray .Reward[1],671,10; // Reward for all members of conquering guilds, per castle: <ID>,<Count>{,...} (0 to disable) ?

I tried but players get nothing

It's no longer needed, really. I added a feature to auto-mail rewards to Guild Masters in v1.5 of my controller: trunk/npc/custom/woe_controller.txt

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  72
  • Topics Per Day:  0.02
  • Content Count:  2997
  • Reputation:   1130
  • Joined:  05/27/12
  • Last Seen:  

v1.5

You're using a previous version.

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...