Enhanced CTF Gamemode for UnrealTournament. It adds the following features compared to the default CTF gamemode:
The settings for clients/players can be found in NewCTF.ini in your System folder, the contents of which will be similar to this:
[ClientSettings]
AnnouncerVolume=1.5
CTFAnnouncerClass=NewCTF_v17.DefaultAnnouncer
Debug=False
_Version=1
Controls the volume of announcements. Valid settings range from 0.0
to 6.0
.
Which announcements to use. NewCTF comes with two announcers: NewCTF_v17.DefaultAnnouncer and NewCTF_v17.NewCTFAnnouncer.
Announcers can have custom sounds for the following CTF events:
Note that all announcements play in addition to the games internal sounds
Only provides custom sounds for Overtime, Advantage, and Draw, which would not have sounds otherwise.
Provides sounds for all events.
If you want to create your own Announcer package for NewCTF, create a new package containing a class that extends INewCTFAnnouncer
from the NewCTFInterface package. Then set CTFAnnouncerClass
to the name of your new package followed by a dot, followed by the name of the class.
Setting this to true causes NewCTF to log all incoming announcement notifications.
This is an version number for your settings, used to automatically upgrade your settings with new versions of NewCTF.
The settings for servers can be found in UnrealTournament.ini in your System folder, the contents of which will be similar to this:
[NewCTF_v17.NewCTF]
SpawnSystemThreshold=4
SpawnEnemyBlockRange=650.0
SpawnEnemyVisionBlockRange=2000.0
SpawnFriendlyBlockRange=150.0
SpawnFriendlyVisionBlockRange=150.0
SpawnFlagBlockRange=750.0
SpawnMinCycleDistance=1
bSpawnExtrapolateMovement=True
bSpawnSecondaryEnabled=True
SpawnSecondaryMaxDistance=2000.0
SpawnSecondaryOwnTeamWeight=0.2
SpawnSecondaryCarrierWeight=2.0
bAllowOvertime=False
RespawnDelay=1.0
OvertimeRespawnDelay=1.0
OvertimeRespawnDelayCoefficient=120.0
OvertimeRespawnDelayStartTime=300
AdvantageDuration=120
AdvantageMaxScoreDiff=-1
MercyScore=0
bFlagGlow=True
FlagTimeout=25.0
FlagAdvantageTimeout=25.0
FlagOvertimeTimeout=25.0
SpectatorPassword=""
bAllowChangingTeams=True
bAllowChangingNames=True
bEnableAssignedTeams=False
AssignedTeamStrategy="0000011111"
These settings will be explained in the Spawn System section.
Whether to allow a match to go into overtime, or to end the game in a draw.
Can also be set through the URL using ?bAllowOvertime=(true/false)
.
See also Interaction with Overtime.
This is the default delay after death for player before they can respawn. Applies throughout the game until OvertimeRespawnDelayStartTime has been reached.
After OvertimeRespawnDelayStartTime seconds of overtime respawning is delayed by this many seconds (at least 1 second).
Only applies if greater than 0.0
.
Every this many seconds of overtime past OvertimeRespawnDelayStartTime respawning is delayed by one additional second.
After this many seconds of overtime, respawning could be delayed by more than normal, depending on OvertimeRespawnDelay and OvertimeRespawnDelayCoefficient.
How much time (in seconds) to add on top of the regular time to allow flags in play at the end to be resolved. Note that due to implementation details AdvantageDuration can not be set to 60 seconds. NewCTF will write a warning about this to the log and set AdvantageDuration to 59 automatically.
Can also be set through the URL using ?AdvantageDuration=X
.
See section Advantage.
This is intended to allow limiting when advantage can happen by looking at the difference in score between the two teams and not going to advantage when the difference is greater than the value of this setting.
Negative values for this setting disable it, so advantage can always kick in.
If MercyScore is greater than 0, and one team is at least one more than
MercyScore ahead of their closest opponent, the game ends immediately.
Can also be set through the URL using ?MercyScore=X
.
Controls whether flags glow when being carried by players.
Can also be set through the URL using bFlagGlow=(True/False)
.
Controls how long a flag stays on the ground before being returned automatically. This variable controls the Timeout during normal play.
Controls how long a flag stays on the ground before being returned automatically during advantage.
Controls how long a flag stays on the ground before being returned automatically during overtime.
If set, players that use it will automatically be assigned the spectator role upon joining the server.
Must not be the same as GamePassword
.
Controls whether players are able to change teams after joining.
Controls whether players are able to change their names after joining.
Enables assigning players to teams based on the password they use. The individual passwords are contained in GamePassword and to be separated by ;
. The team those players are assigned to is determined by AssignedTeamStrategy
.
Optionally the password can contain a player name, that the player using the password will be forced to upon joining. The name does not need to be entered as part of the password and is separated from the password by %
.
Controls which team players are assigned to depending on the position inside GamePassword
of the password they used. The first character in this string determines the team for the first non-empty password in GamePassword
, etc.. If the character is s
or S
then the associated password is assigned to SpectatorPassword
, else its expected to be a team number between 0 and 3.
Number | Team |
---|---|
0 | Red |
1 | Blue |
2 | Green |
3 | Gold |
NewCTF comes with a new spawn system, replacing the default one. For the purposes of this document, spawn point and PlayerStart refer to the same thing.
If the number of players on the server is less than or equal to SpawnSystemThreshold
, the default spawn algorithm of UT99 is used.
NewCTF has a list of spawn points for each team, which is created at the start of each map and shuffled once.
NewCTF has two spawn systems called primary system and secondary system. The primary system tries to find a high-quality spawn point. If the primary system does not find a suitable spawn point, the secondary system is used, which will result in spawns that violate one or more of the rules of the primary system.
Every time a player tries to respawn during the game, the primary spawn system goes through the list of that player's team and tries to find a spawn point that can be used given the following restrictions:
SpawnEnemyBlockRange
of the spawn point,SpawnEnemyVisionBlockRange
and has vision of the spawn point (tracing EyeHeight of player to Location of spawn point),SpawnFriendlyBlockRange
of the spawn point,SpawnFriendlyVisionBlockRange
and has vision of the spawn point,SpawnFlagBlockRange
of the spawn point andSpawnMinCycleDistance
other spawn points have been used since the last time this one was usedIf no suitable spawn point can be found, the system falls back to the secondary system.
The secondary system finds the spawn point thats furthest away from all players. It does this by adding up the distance of every player for each spawn point. The spawn point with the highest sum is then used to spawn. For certain classes of players, the distance can be modified using the following settings:
SpawnSecondaryOwnTeamWeight
(members of the same team)SpawnSecondaryCarrierWeight
(enemy flag carriers)Keep in mind that if you want to prioritize spawning next to a certain class of players, you want to decrease the weight compared to the default for enemies, which is 1.0
.
The spawn point selected by one of the two systems is moved to the end of the list.
Specifies the maximum number of players on a map that will not use the new spawn system. Set to 0 to always use it, or to a very high value to never use it.
Specifies the range within which an enemy will block a spawn from being used, no matter the visibility.
Specifies the range within which an enemy with vision of the spawn point will block it from being used.
Specifies the range within which a teammate will block a spawn from being used, regardless of visibility.
Specifies the range within which a teammate with vision of the spawn point will block it from being used.
Specifies the range within which a Flag will block a spawn from being used, regardless of visibility.
Specifies the number of other spawn points that have to have been used before a given spawn point can be used again. Setting it to 0 disables this restriction.
If enabled, use extrapolated position of remote player for range checks of spawn points.
If enabled, use secondary algorithm to find a suitable spawn point if primary algorithm cant find one. If disabled, skip using secondary algorithm and fall back to default algorithm.
Players at or above this distance from a spawn point all contribute the same amount to its weight for the secondary algorithm.
Multiplier of the distance of members of the same team to spawn points.
Multiplier of the distance of flag carriers to spawn points.
If enabled, replaces the default flag drop behaviour. When a flag is dropped by a player, it will move in the player's last velocity direction at a maximum speed of FlagDropMaximumSpeed.
Limits the maximum speed of a flag to this value when it is dropped. Only applies if bEnableModifiedFlagDrop is enabled.
NewCTFInterface contains an add-on for map makers that allows them to provide alternate spawn system settings for a single map.
For this purpose NewCTFInterface contains two placeable actors, SpawnControlInfo
and SpawnControlPlayerStart
.
In order to use it, place the file NewCTFInterface.u in your System folder and add EditPackages=NewCTFInterface
to section [Editor.EditorEngine]
in UnrealTournament.ini.
Can be placed anywhere on the map, is invisible and contains alternate settings for the entire map.
This is a replacement for the default PlayerStart. It behaves like it in every way, but provides a way to override Range settings of the spawn system for a single spawn point.
NewCTF places a player dummy on each spawn point until the match starts. Its texture indicates whether the spawn point would be used by the primary algorithm.
NewCTF introduces an advantage system which delays the end of a match if at least one flag is not on its FlagBase at the end of the regular time. Advantage will end once all flags are on their FlagBases, either by being returned or by being captured, or alternatively it will end when the additional time granted by the AdvantageDuration setting runs out.
Advantage applies even if overtime is allowed.
The game might first go into Advantage, then into Overtime if the resolution of Advantage resulted in a drawn game.
git clone https://github.com/Deaod/NewCTF.git