RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Capture the Flag and Double Domination games (Updated)

DLocke5463

Wanderer
Help

I put the script into my scripts folder and no errors except one saying the namespace Leave gate in the line that says

public class LeaveGameGate : ConfirmationMoongate

My server does not comprehend what a confirmation moongate is how do i fix this problem
 

Dark Lord

Wanderer
Originally Posted by crash
Mobiles: 15382
Items: 176192
Clients:
- Count: 4

Exception:
System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
at System.Collections.ArrayList.get_Item(Int32 index)
at Server.Items.CTFGame.StartGame(Boolean resetTeams)
at Server.Items.CTFGame.StartGame_Target(Mobile from, Object o,
Bia: Object state)
at Server.SimpleStateTarget.OnTarget(Mobile from, Object targeted)
at Server.Targeting.Target.Invoke(Mobile from, Object targeted)
at Server.Network.PacketHandlers.TargetResponse(NetState state, PacketReader pvSrc)
at Server.Network.MessagePump.HandleReceive(NetState ns)
at Server.Network.MessagePump.Slice()
at Server.Core.Main(String[] args)

Solution:

In file 'СTFGame.cs' on line 502 change
Code:
Mobile m = (Mobile)t.Members[i];
to
Code:
Mobile m = (Mobile)t.Members[j];
 

DLocke5463

Wanderer
Help me if you can

I am getting this error when i put the script into my scripts folder

'ConfirmationMoongate' could not be found <are you missing a using using directive or an assembly reference?>

Apparently confirmation moongate is some kind of added in script and i dont seem to have it where can i get it if that is the problem
 

bean56

Wanderer
$100 says you are using b36 and need to update to 1.0 or edit the script yourself. It is not an "added in script".
 

coldrake

Wanderer
There is still an issue with player mobiles lingering in game after lost connection. If a player loses connection during a game, his player mobile is stuck in the game. It never goes to the internal map. This causes an issue when lets say a new player to the shard logs in, plays CTF or DD, the loses connection. The player decides to not return to the shard, meanwhile... you have his player mobile lingering in the red team home base for weeks, months.

Come on, this is a HUGE bug... don't you have a fix or at least some suggestions on how to fix it?
 

bean56

Wanderer
coldrake said:
There is still an issue with player mobiles lingering in game after lost connection. If a player loses connection during a game, his player mobile is stuck in the game. It never goes to the internal map. This causes an issue when lets say a new player to the shard logs in, plays CTF or DD, the loses connection. The player decides to not return to the shard, meanwhile... you have his player mobile lingering in the red team home base for weeks, months.

Come on, this is a HUGE bug... don't you have a fix or at least some suggestions on how to fix it?
Delete their account.
 

Maseral

Wanderer
Saxum said:
Thanks a lot for your help bean56.

Is anyone aware of how you can change the script so random teams exist only? And with teambalance so one team wont have 5 players and one 1.

some one Know`s ? i want a random team selector 10 eatch team :p
 

bean56

Wanderer
I changed it so they can only have 1 more than the other team, but not random. It wouldn't be that hard to do. I'm sure you can try it and get help in script support, maybe even by me.
 

Zero_X

Wanderer
This is what I did to make the teams random, but well, lol you'll see it when you do this. This simply chooses a random team, but if the team is full, you'll have to click again. I've seen a different system on Defiance, which is leeter but ah well... :)

So heres what you do, first you change the max difference in a team.

CTFGame.cs

Look for

Code:
		public int TeamSize
		{
			get
			{
				int count = 0;
				for (int i=0;i<this.Teams.Count;i++)
					count += ((CTFTeam)m_Teams[i]).ActiveMemberCount;

				count /= Teams.Count;
				return count + 5;
			}
		}

This part

Code:
				return count + 5;

Change the + 5 into + 1 so it looks like

Code:
		public int TeamSize
		{
			get
			{
				int count = 0;
				for (int i=0;i<this.Teams.Count;i++)
					count += ((CTFTeam)m_Teams[i]).ActiveMemberCount;

				count /= Teams.Count;
				return count + 1;
			}
		}

Save the file and exit.

Now look for GameJoinGump.cs

Find

Code:
				{
					AddButton( 20, 60 + i*20, 4005, 4006, i+1, GumpButtonType.Reply, 0 );
					AddLabel( 55, 60 + i*20, 0, "Join Team " + team.Name );	
				}

Replace it with

Code:
				{
					AddButton( 20, 60, 4005, 4006, i+1, GumpButtonType.Reply, 0 );
					AddLabel( 55, 60, 0, "Join Random Team" );	
				}

Now look for

Code:
			CTFTeam team = m_Game.GetTeam( info.ButtonID - 1 );

Replace it with

Code:
			CTFTeam team = m_Game.GetTeam(Utility.Random( m_Game.Teams.Count ) );

Now save and reboot/start your server.

^^
 

Element1

Wanderer
i need help

im a noob havent been scripting logn but for the ctf im useing the old ctf rink and i had it all set up and i just dont know where to type the coords in at to make it go to that ctf rink and where to name all the teams and also i was wondering if i can make it so they cant pick the team. you have to pick random. Thanks!
 

light875

Wanderer
Great scripts and great idea.

Only problem i`ve got now is my players can`t score as each time they get a flag to their own base they can`t drop it on their own flag.

Can pick it up fine by dbl clicking, but can`t seem to drop.

Is the drop location scripted by co-ordiinate or is it just local to the carriers flag?

** Fixed it now, didn`t realise i had to dbl click the flag to score as well. **
 

light875

Wanderer
coldrake said:
Ok I changed the scoreboard to doubleclick and it is working now.


How?

All i get when i hold the mouse over the sign or click ( single or double ) is the sign`s name "CTF Score Board"
 

aecio

Wanderer
hi i have a problem...i new in this and my english sux...but i want play ctf in my server....this is my problem i dont see the ctfgame stone and gamejoinstone.....
 

Crepti

Wanderer
I've just installed CTF, and I'm having a problem with it.
My after a game has ended, and the players have gone and done their own thing etc, if they log out, when they log back in they're at their old CTF 'Home'. The game isn't running, but they're logging in in the CTF arena. How can I prevent this?
 

Phantom

Knight
You find where the code isn't working and you correct the code?

Not exactly sure what you want from a script that isn't being updated anymore.
 

Sowz

Wanderer
The design of CTF arena are not the same in each corner, how can this be ?
I would like to have the same stairway in each base as there is in one of em, but i dont know how to do that or where to get it if allready made.

Hope to get some help here, thanks :)
 
Top