What's new

Discussion [RELEASE] Spawn Mod

Z89

zackf89

Xbox Modification/Repair Master
Messages
1,574
Reaction score
893
Points
230
This is a basic spawn mod to always spawn each team at their starting spawn...ill update it later w/ other variations to lazy atm

replace your whole dd.gsc w/ this code

the only downside is the spawnmod only works when you set the game to demolition but it will be TDM

Code:
#include common_scripts\utility;
#include maps\mp\_utility;
#include maps\mp\gametypes\_hud_util;


main()
{
maps\mp\gametypes\_globallogic::init();
maps\mp\gametypes\_callbacksetup::SetupCallbacks();
maps\mp\gametypes\_globallogic::SetupCallbacks();

registerTimeLimitDvar( level.gameType, 10, 0, 1440 );
registerScoreLimitDvar( level.gameType, 1000, 0, 5000 );
registerWinLimitDvar( level.gameType, 1, 0, 5000 );
registerRoundLimitDvar( level.gameType, 1, 0, 10 );
registerNumLivesDvar( level.gameType, 0, 0, 10 );
registerHalfTimeDvar( level.gameType, 0, 0, 1 );

level.onStartGameType = ::onStartGameType;
level.getSpawnPoint = ::getSpawnPoint;

game["dialog"]["gametype"] = "freeforall";

if ( getDvarInt( "g_hardcore" ) )
game["dialog"]["gametype"] = "hc_" + game["dialog"]["gametype"];
else if ( getDvarInt( "camera_thirdPerson" ) )
game["dialog"]["gametype"] = "thirdp_" + game["dialog"]["gametype"];
else if ( getDvarInt( "scr_diehard" ) )
game["dialog"]["gametype"] = "dh_" + game["dialog"]["gametype"];
else if (getDvarInt( "scr_" + level.gameType + "_promode" ) )
game["dialog"]["gametype"] = game["dialog"]["gametype"] + "_pro";
}


onStartGameType()
{
setClientNameMode("auto_change");

setObjectiveText( "allies", &"OBJECTIVES_DM" );
setObjectiveText( "axis", &"OBJECTIVES_DM" );

if ( level.splitscreen )
{
setObjectiveScoreText( "allies", &"OBJECTIVES_DM" );
setObjectiveScoreText( "axis", &"OBJECTIVES_DM" );
}
else
{
setObjectiveScoreText( "allies", &"OBJECTIVES_DM_SCORE" );
setObjectiveScoreText( "axis", &"OBJECTIVES_DM_SCORE" );
}
setObjectiveHintText( "allies", &"OBJECTIVES_DM_HINT" );
setObjectiveHintText( "axis", &"OBJECTIVES_DM_HINT" );

level.spawnMins = ( 0, 0, 0 );
level.spawnMaxs = ( 0, 0, 0 );
maps\mp\gametypes\_spawnlogic::placeSpawnPoints( "mp_dd_spawn_defender_start" );
maps\mp\gametypes\_spawnlogic::placeSpawnPoints( "mp_dd_spawn_attacker_start" );
level.mapCenter = maps\mp\gametypes\_spawnlogic::findBoxCenter( level.spawnMins, level.spawnMaxs );
setMapCenter( level.mapCenter );
level.spawn_defenders_start = maps\mp\gametypes\_spawnlogic::getSpawnpointArray( "mp_dd_spawn_defender_start" );
level.spawn_attackers_start = maps\mp\gametypes\_spawnlogic::getSpawnpointArray( "mp_dd_spawn_attacker_start" );

allowed[0] = "dm";
maps\mp\gametypes\_gameobjects::main(allowed);

maps\mp\gametypes\_rank::registerScoreInfo( "kill", 0 );
maps\mp\gametypes\_rank::registerScoreInfo( "headshot", 50 );
maps\mp\gametypes\_rank::registerScoreInfo( "assist", 10 );
maps\mp\gametypes\_rank::registerScoreInfo( "suicide", 0 );
maps\mp\gametypes\_rank::registerScoreInfo( "teamkill", 0 );

level.QuickMessageToAll = true;
}


getSpawnPoint()
{
spawnteam = self.pers["team"];

if ( level.useStartSpawns )
{
if ( spawnteam == game["allies"] )
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_attackers_start);
else
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_defenders_start);
}	
else
{
if ( spawnteam == game["allies"] )
{
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_attackers_start);
}
else
{
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_defenders_start);
}
}

assert( isDefined(spawnpoint) );

return spawnpoint;
}
 
T

Tag My Jay

Enthusiast
Messages
404
Reaction score
61
Points
85
This is a basic spawn mod to always spawn each team at their starting spawn...ill update it later w/ other variations to lazy atm

replace your whole dd.gsc w/ this code

the only downside is the spawnmod only works when you set the game to demolition but it will be TDM

Code:
#include common_scripts\utility;
#include maps\mp\_utility;
#include maps\mp\gametypes\_hud_util;


main()
{
maps\mp\gametypes\_globallogic::init();
maps\mp\gametypes\_callbacksetup::SetupCallbacks();
maps\mp\gametypes\_globallogic::SetupCallbacks();

registerTimeLimitDvar( level.gameType, 10, 0, 1440 );
registerScoreLimitDvar( level.gameType, 1000, 0, 5000 );
registerWinLimitDvar( level.gameType, 1, 0, 5000 );
registerRoundLimitDvar( level.gameType, 1, 0, 10 );
registerNumLivesDvar( level.gameType, 0, 0, 10 );
registerHalfTimeDvar( level.gameType, 0, 0, 1 );

level.onStartGameType = ::onStartGameType;
level.getSpawnPoint = ::getSpawnPoint;

game["dialog"]["gametype"] = "freeforall";

if ( getDvarInt( "g_hardcore" ) )
game["dialog"]["gametype"] = "hc_" + game["dialog"]["gametype"];
else if ( getDvarInt( "camera_thirdPerson" ) )
game["dialog"]["gametype"] = "thirdp_" + game["dialog"]["gametype"];
else if ( getDvarInt( "scr_diehard" ) )
game["dialog"]["gametype"] = "dh_" + game["dialog"]["gametype"];
else if (getDvarInt( "scr_" + level.gameType + "_promode" ) )
game["dialog"]["gametype"] = game["dialog"]["gametype"] + "_pro";
}


onStartGameType()
{
setClientNameMode("auto_change");

setObjectiveText( "allies", &"OBJECTIVES_DM" );
setObjectiveText( "axis", &"OBJECTIVES_DM" );

if ( level.splitscreen )
{
setObjectiveScoreText( "allies", &"OBJECTIVES_DM" );
setObjectiveScoreText( "axis", &"OBJECTIVES_DM" );
}
else
{
setObjectiveScoreText( "allies", &"OBJECTIVES_DM_SCORE" );
setObjectiveScoreText( "axis", &"OBJECTIVES_DM_SCORE" );
}
setObjectiveHintText( "allies", &"OBJECTIVES_DM_HINT" );
setObjectiveHintText( "axis", &"OBJECTIVES_DM_HINT" );

level.spawnMins = ( 0, 0, 0 );
level.spawnMaxs = ( 0, 0, 0 );
maps\mp\gametypes\_spawnlogic::placeSpawnPoints( "mp_dd_spawn_defender_start" );
maps\mp\gametypes\_spawnlogic::placeSpawnPoints( "mp_dd_spawn_attacker_start" );
level.mapCenter = maps\mp\gametypes\_spawnlogic::findBoxCenter( level.spawnMins, level.spawnMaxs );
setMapCenter( level.mapCenter );
level.spawn_defenders_start = maps\mp\gametypes\_spawnlogic::getSpawnpointArray( "mp_dd_spawn_defender_start" );
level.spawn_attackers_start = maps\mp\gametypes\_spawnlogic::getSpawnpointArray( "mp_dd_spawn_attacker_start" );

allowed[0] = "dm";
maps\mp\gametypes\_gameobjects::main(allowed);

maps\mp\gametypes\_rank::registerScoreInfo( "kill", 0 );
maps\mp\gametypes\_rank::registerScoreInfo( "headshot", 50 );
maps\mp\gametypes\_rank::registerScoreInfo( "assist", 10 );
maps\mp\gametypes\_rank::registerScoreInfo( "suicide", 0 );
maps\mp\gametypes\_rank::registerScoreInfo( "teamkill", 0 );

level.QuickMessageToAll = true;
}


getSpawnPoint()
{
spawnteam = self.pers["team"];

if ( level.useStartSpawns )
{
if ( spawnteam == game["allies"] )
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_attackers_start);
else
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_defenders_start);
}	
else
{
if ( spawnteam == game["allies"] )
{
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_attackers_start);
}
else
{
spawnpoint = maps\mp\gametypes\_spawnlogic::getSpawnpoint_Random(level.spawn_defenders_start);
}
}

assert( isDefined(spawnpoint) );

return spawnpoint;
}
+1
 
z IFuILILeTe z

z IFuILILeTe z

Enthusiast
Messages
669
Reaction score
223
Points
125
has anyone tested this?\ it seems interesting.. if this has been tested do reply......,,
 
Z89

zackf89

Xbox Modification/Repair Master
Messages
1,574
Reaction score
893
Points
230
works 100% ive been using it for a few weeks now i have other variations where everybody spawns in the middle of the map and drops in like in halo 2 :smile:
 
Grimmyyy

Grimmyyy

Newbie
Messages
37
Reaction score
0
Points
45
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
biggrin.gif
 
T

The Benjineer

Enthusiast
Messages
53
Reaction score
3
Points
55
can someone help me out with this please? i want everyone to spawn the same place and not sure how to do it.
 
laxdevil91

laxdevil91

Enthusiast
Messages
192
Reaction score
6
Points
70
im going to guess you have to have a jtagged xbox for this. or can i do it with xport ?
 
ReFLexX IV

ReFLexX IV

Enthusiast
Messages
1,001
Reaction score
140
Points
165
Bump1.jpg


Lol I was looking around and I found this and it needs to be brought back up :wink:
 
WaTcH HoW i MoD

WaTcH HoW i MoD

Enthusiast
Messages
1,459
Reaction score
379
Points
165
so where they originally spawn thats where they always spawn?
 
Top Bottom
Login
Register