Jump to content
  • 0
Sign in to follow this  
Alayne

Issue with battleground warping

Question

Hi peoples,

 

I have serious issue with custom battleground addons.

Even the base mechs doesn't work, as I can't get players to be warped to fighting zone as awaited.

 

Here's the associated code:

 

bat_room,120,157,4	script	Registration::Fl2R_Croixs	414,{
	end;
OnInit:
	waitingroom "Team Croix",5,"Flavius_BG2_Custom::OnCroixJoin",1;
	end;
OnEnterBG:
	if($@FlaviusBG2 == 0) {
		set $@FlaviusBG2_id2, waitingroom2bg("bat_b02",10,290,"Flavius_BG2_Custom::OnCroixQuit","");
		bg_warp $@FlaviusBG2_id2,"bat_b02",10,290;
		//debugmes "C: " + $@FlaviusBG2_id2;
		//sleep 10000;
		end;
	}
	if($@FlaviusBG2 == 1) {
		debugmes "single join";
		waitingroom2bg_single($@FlaviusBG2_id2,"bat_b02",10,290,"");
		warp "bat_b02",10,290;
	}	
	end;
}

for both registration npcs,

 


OnReadyCheck:
	set .@Guillaume, getwaitingroomstate(0,"Fl2R_Guillaumes");
	set .@Croix, getwaitingroomstate(0,"Fl2R_Croixs");
	set .@currentGuillaumePlayer, bg_get_data($@FlaviusBG2_id1, 0);
	set .@currentCroixPlayer, bg_get_data($@FlaviusBG2_id2, 0);
	//debugmes "G: " + (.@Guillaume + .@currentGuillaumePlayer) + ", C: " + (.@Croix + .@currentCroixPlayer);
	if($@FlaviusBG2 == 0) {
		if( .@Guillaume + .@currentGuillaumePlayer < .BGMinPlayer || .@Croix + .@currentCroixPlayer < .BGMinPlayer ) {
			mapannounce "prontera","Battleground G: " + .@Guillaume + ", C: " + .@Croix,1,0x808000;
			end;
		} else {
			donpcevent "Fl2R_Guillaumes::OnEnterBG";
			donpcevent "Fl2R_Croixs::OnEnterBG";
		}
	}
	if($@FlaviusBG2 == 1) {
		debugmes "join";
		donpcevent "Fl2R_Guillaumes::OnEnterBG";
		donpcevent "Fl2R_Croixs::OnEnterBG";
		goto OnUpdateScoreBoard;
	}

and the starting bg part.

I got all the debugmes as they should be, but nothing works, players aren't warped.

 

Right there there should be two different warps: starting ones (2 players, one in each waitingroom), and a second one for anybody joining once the match is started (with the waitingroom2bg_single).

 

Can anybody give me a hint on what I'm missing?

Share this post


Link to post
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

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

  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.

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.