Merge branch 'release/pre' of github.com:RaidMax/IW4M-Admin into release/pre

This commit is contained in:
RaidMax 2023-04-07 20:53:25 -05:00
commit 6bb97c7d83
9 changed files with 136 additions and 17 deletions

View File

@ -69,6 +69,39 @@
} }
], ],
"Gametypes": [ "Gametypes": [
{
"Game": "IW3",
"Gametypes": [
{
"Name": "ctf",
"Alias": "Capture The Flag"
},
{
"Name": "dm",
"Alias": "Free For All"
},
{
"Name": "dom",
"Alias": "Domination"
},
{
"Name": "koth",
"Alias": "Headquarters"
},
{
"Name": "sab",
"Alias": "Sabotage"
},
{
"Name": "sd",
"Alias": "Search & Destroy"
},
{
"Name": "war",
"Alias": "Team Deathmatch"
}
]
},
{ {
"Game": "IW4", "Game": "IW4",
"Gametypes": [ "Gametypes": [
@ -152,6 +185,10 @@
{ {
"Name": "twar", "Name": "twar",
"Alias": "War" "Alias": "War"
},
{
"Name": "cmp",
"Alias": "Zombies"
} }
] ]
}, },
@ -404,6 +441,14 @@
{ {
"Name": "tdm", "Name": "tdm",
"Alias": "Team Deathmatch" "Alias": "Team Deathmatch"
},
{
"Name": "zclassic",
"Alias": "Zombies Classic"
},
{
"Name": "zstandard",
"Alias": "Zombies"
} }
] ]
}, },
@ -505,6 +550,10 @@
{ {
"Name": "hc_tdm", "Name": "hc_tdm",
"Alias": "Hardcore Team Deathmatch" "Alias": "Hardcore Team Deathmatch"
},
{
"Name": "zclassic",
"Alias": "Zombies Classic"
} }
] ]
}, },
@ -1612,6 +1661,70 @@
{ {
"Alias": "Outlaw", "Alias": "Outlaw",
"Name": "mp_western" "Name": "mp_western"
},
{
"Alias": "Fringe Night",
"Name": "mp_veiled_heyday"
},
{
"Alias": "Redwood Snow",
"Name": "mp_redwood_ice"
},
{
"Alias": "Shadows of Evil",
"Name": "zm_zod"
},
{
"Alias": "Der Eisendrache",
"Name": "zm_castle"
},
{
"Alias": "Zetsubou No Shima",
"Name": "zm_island"
},
{
"Alias": "Gorod Krovi",
"Name": "zm_stalingrad"
},
{
"Alias": "Revelations",
"Name": "zm_genesis"
},
{
"Alias": "Ascension",
"Name": "zm_cosmodrome"
},
{
"Alias": "Kino der Toten",
"Name": "zm_theater"
},
{
"Alias": "Moom",
"Name": "zm_moon"
},
{
"Alias": "Nacht der Untoten",
"Name": "zm_prototype"
},
{
"Alias": "Origins",
"Name": "zm_tomb"
},
{
"Alias": "Shangri-La",
"Name": "zm_temple"
},
{
"Alias": "Shi No Numa",
"Name": "zm_sumpf"
},
{
"Alias": "The Giant",
"Name": "zm_factory"
},
{
"Alias": "Verrückt",
"Name": "zm_asylum"
} }
] ]
}, },

View File

@ -41,11 +41,11 @@ waitForAttack()
{ {
self endon( "disconnect" ); self endon( "disconnect" );
self notifyOnPlayerCommand( "player_shot", "+attack" );
self.lastAttackTime = 0; self.lastAttackTime = 0;
for( ;; ) for( ;; )
{ {
self notifyOnPlayerCommand( "player_shot", "+attack" );
self waittill( "player_shot" ); self waittill( "player_shot" );
self.lastAttackTime = getTime(); self.lastAttackTime = getTime();

View File

@ -40,11 +40,11 @@ waitForAttack()
{ {
self endon( "disconnect" ); self endon( "disconnect" );
self notifyOnPlayerCommand( "player_shot", "+attack" );
self.lastAttackTime = 0; self.lastAttackTime = 0;
for( ;; ) for( ;; )
{ {
self notifyOnPlayerCommand( "player_shot", "+attack" );
self waittill( "player_shot" ); self waittill( "player_shot" );
self.lastAttackTime = getTime(); self.lastAttackTime = getTime();

View File

@ -41,17 +41,16 @@ onPlayerConnect( player )
} }
} }
//Got added to T6 on April 2020 //Got added to T6 on April 2020
waitForAttack() waitForAttack()
{ {
self endon( "disconnect" ); self endon( "disconnect" );
self notifyOnPlayerCommand( "player_shot", "+attack" );
self.lastAttackTime = 0; self.lastAttackTime = 0;
for( ;; ) for( ;; )
{ {
self notifyOnPlayerCommand( "player_shot", "+attack" );
self waittill( "player_shot" ); self waittill( "player_shot" );
self.lastAttackTime = getTime(); self.lastAttackTime = getTime();

View File

@ -4,7 +4,7 @@
Init() Init()
{ {
level thread Setup(); thread Setup();
} }
Setup() Setup()
@ -21,6 +21,7 @@ Setup()
level.commonFunctions = spawnstruct(); level.commonFunctions = spawnstruct();
level.commonFunctions.setDvar = "SetDvarIfUninitialized"; level.commonFunctions.setDvar = "SetDvarIfUninitialized";
level.commonFunctions.isBot = "IsBot";
level.commonKeys = spawnstruct(); level.commonKeys = spawnstruct();

View File

@ -4,7 +4,7 @@ Init()
{ {
level.eventBus.gamename = "IW4"; level.eventBus.gamename = "IW4";
level thread Setup(); thread Setup();
} }
Setup() Setup()
@ -18,6 +18,7 @@ Setup()
level.overrideMethods["GetTotalShotsFired"] = ::GetTotalShotsFired; level.overrideMethods["GetTotalShotsFired"] = ::GetTotalShotsFired;
level.overrideMethods[level.commonFunctions.setDvar] = ::_SetDvarIfUninitialized; level.overrideMethods[level.commonFunctions.setDvar] = ::_SetDvarIfUninitialized;
level.overrideMethods[level.commonFunctions.isBot] = ::IsTestClient;
level.overrideMethods["waittill_notify_or_timeout"] = ::_waittill_notify_or_timeout; level.overrideMethods["waittill_notify_or_timeout"] = ::_waittill_notify_or_timeout;
level.overrideMethods[level.commonFunctions.changeTeam] = ::ChangeTeam; level.overrideMethods[level.commonFunctions.changeTeam] = ::ChangeTeam;
level.overrideMethods[level.commonFunctions.getTeamCounts] = ::CountPlayers; level.overrideMethods[level.commonFunctions.getTeamCounts] = ::CountPlayers;
@ -48,7 +49,7 @@ OnPlayerConnect()
{ {
level waittill( "connected", player ); level waittill( "connected", player );
if ( scripts\_integration_base::_IsBot( player ) ) if ( player call [[ level.overrideMethods[ level.commonFunctions.isBot ] ]]() )
{ {
// we don't want to track bots // we don't want to track bots
continue; continue;
@ -441,7 +442,9 @@ NoClipImpl()
self SetClientDvar( "sv_cheats", 0 ); self SetClientDvar( "sv_cheats", 0 );
self God(); self God();
self Noclip();
self.clientflags |= 1; // IW4x specific
self Hide(); self Hide();
self.isNoClipped = true; self.isNoClipped = true;
@ -455,7 +458,9 @@ NoClipImpl()
self SetClientDvar( "sv_cheats", 0 ); self SetClientDvar( "sv_cheats", 0 );
self God(); self God();
self Noclip();
self.clientflags &= ~1; // IW4x specific
self Show(); self Show();
self.isNoClipped = false; self.isNoClipped = false;

View File

@ -4,7 +4,7 @@ Init()
{ {
level.eventBus.gamename = "IW5"; level.eventBus.gamename = "IW5";
level thread Setup(); thread Setup();
} }
Setup() Setup()
@ -19,6 +19,7 @@ Setup()
level.overrideMethods["GetTotalShotsFired"] = ::GetTotalShotsFired; level.overrideMethods["GetTotalShotsFired"] = ::GetTotalShotsFired;
level.overrideMethods["SetDvarIfUninitialized"] = ::_SetDvarIfUninitialized; level.overrideMethods["SetDvarIfUninitialized"] = ::_SetDvarIfUninitialized;
level.overrideMethods["waittill_notify_or_timeout"] = ::_waittill_notify_or_timeout; level.overrideMethods["waittill_notify_or_timeout"] = ::_waittill_notify_or_timeout;
level.overrideMethods[level.commonFunctions.isBot] = ::IsTestClient;
RegisterClientCommands(); RegisterClientCommands();
@ -40,7 +41,7 @@ OnPlayerConnect()
{ {
level waittill( "connected", player ); level waittill( "connected", player );
if ( scripts\mp\_integration_base::_IsBot( player ) ) if ( player call [[ level.overrideMethods[ level.commonFunctions.isBot ] ]]() )
{ {
// we don't want to track bots // we don't want to track bots
continue; continue;

View File

@ -1,7 +1,7 @@
Init() Init()
{ {
level thread Setup(); thread Setup();
} }
Setup() Setup()

View File

@ -4,7 +4,7 @@ Init()
{ {
level.eventBus.gamename = "T5"; level.eventBus.gamename = "T5";
level thread Setup(); thread Setup();
} }
Setup() Setup()