need help woe prize giver

glemor123

New member
Messages
287
Points
0
the problem to my woe prize giver is example

omega guild owns 3 castle already fad,swan,arug

then today the castle opened is swan then guild omega successfully defended there castle

so they will get the prize for swan,.

the problem is they can also get again the prize for fad,arug..that should not be because swan only opened this day

here is my script i am using 3ceam

Code:
zhakastia,98,39,8	script	Woe Prize	1002,{	if ( agitcheck() ) {		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;	}	else if ( agitcheck2() ) {		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;	}	set .@menu, select(.menu$) -1;	if ( getcastledata( .castlemap$[.@menu], 1) == getcharid(2) ) {		if ( $castle_claimed & pow(2, .@menu) ) {			mes "your guild already received the reward for "+ .castlename$[.@menu];			close;		}		else if ( getguildmasterid( getcharid(2) ) == getcharid(0) ) {			mes "receiving the reward for "+ .castlename$[.@menu];			getitem 674, 15;			set $castle_claimed, $castle_claimed | pow(2, .@menu);			close;		}		else {			mes "ask your guild master to see me";			close;		}	}	mes "your guild failed to take "+ .castlename$[.@menu];	mes "if your guild owned a castle ask your guild master to claim reward from me";	close;OnAgitEnd:	set $castle_claimed, 0; // everytime woe ends the variable resets	end;OnInit:	setarray .castlemap$,		"arug_cas03",		"aldeg_cas05",		"gefg_cas04",		"payg_cas03",		"prtg_cas02";	for ( set .@i, 0; .@i < 5; set .@i, .@i +1 ) {		set .castlename$[.@i], getcastlename(.castlemap$[.@i]);		set .menu$, .menu$ + .castlename$[.@i] +":";	}	}
 
show your WOE schedule .....

OnAgitEnd: set $castle_claimed, 0; // everytime woe ends the variable resets end;

this part alway reset ... every woe end...so you have to re-create this part to only remove / reset certain castles reward ....

 
Last edited by a moderator:
show your WOE schedule .....

OnAgitEnd: set $castle_claimed, 0; // everytime woe ends the variable resets end;

this part alway reset ... every woe end...so you have to re-create this part to only remove / reset certain castles reward ....
i dont know how to edit the agit end

also

this is my woe schedule

from monday to sunday 14:00-15:00 then from 20:00-21:00

with different castles

monday 14:00-15:00 =swan 20:00-21:00 =payg_cas03

etc..

 
do you have auto giver prize to the guild master only??

but the problem is what if when the woe is over exactly the guild master got disconnected...

 
show your WOE schedule .....

OnAgitEnd: set $castle_claimed, 0; // everytime woe ends the variable resets end;

this part alway reset ... every woe end...so you have to re-create this part to only remove / reset certain castles reward ....
can you give me an example for that so i can recreate it..i dont know how to code those things

 
is this correct??

Code:
zhakastia,98,39,8	script	Woe Prize	1002,{	if ( agitcheck() ) goto L_woeon;	if ( agitcheck2() ) goto L_woeon;	menu 		"Rothenburg",L_aldeg_cas05,		"Bergel",L_gefg_cas04,		"HolyShadow",L_payg_cas03,		"Swanhild",L_prtg_cas02,		"HORN",L_arug_cas03;L_aldeg_cas05:	if ( getcastledata( "aldeg_cas05", 1) != getcharid(2) ) goto L_not_owner;	if ( $castle_claimed[2] ) goto L_claimed;	if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;	mes "receiving the reward for this castle";	getitem 674, 15;	set $castle_claimed[2], 1;	close;L_gefg_cas04:	if ( getcastledata( "gefg_cas04", 1) != getcharid(2) ) goto L_not_owner;	if ( $castle_claimed[3] ) goto L_claimed;	if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;	mes "receiving the reward for this castle";	getitem 674, 15;	set $castle_claimed[3], 1;	close;L_payg_cas03:	if ( getcastledata( "payg_cas03", 1) != getcharid(2) ) goto L_not_owner;	if ( $castle_claimed[4] ) goto L_claimed;	if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;	mes "receiving the reward for this castle";	getitem 674, 15;	set $castle_claimed[4], 1;	close;L_prtg_cas02:	if ( getcastledata( "prtg_cas02", 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 674, 15;	set $castle_claimed[5], 1;	close;L_arug_cas03:	if ( getcastledata( "arug_cas03", 1) != getcharid(2) ) goto L_not_owner;	if ( $castle_claimed[1] ) goto L_claimed;	if ( getguildmasterid( getcharid(2) ) != getcharid(0) ) goto L_not_gm;	mes "receiving the reward for this castle";	getitem 674, 15;	set $castle_claimed[1], 1;	close;L_woeon:	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 "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 "your guild already received the reward for this castle";	close;L_not_gm:	mes "ask your guild master to see me";	close;OnMon1500:	set $castle_claimed[1], 0; // everytime woe ends the variable resets	end;OnMon2100:	set $castle_claimed[2], 0;	end;OnTue1500:	set $castle_claimed[3], 0;end;OnTue2100:	set $castle_claimed[4], 0;end;OnWed1500:	set $castle_claimed[2], 0;	end;OnWed2100:	set $castle_claimed[3], 0;end;OnThu1500:	set $castle_claimed[4], 0;end;OnThu2100:	set $castle_claimed[1], 0; // everytime woe ends the variable resets	end;OnFri1500:	set $castle_claimed[2], 0;	end;OnFri2100:	set $castle_claimed[2], 0;	end;OnSat1500:	set $castle_claimed[5], 0;end;OnSat2100:	set $castle_claimed[5], 0;end;OnSun1500:	set $castle_claimed[5], 0;	end;OnSun2100:	set $castle_claimed[5], 0;	end;}
 
Back
Top