Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
dystopm committed Jan 7, 2024
2 parents 8f1ff1e + 15df1a9 commit a793d77
Show file tree
Hide file tree
Showing 57 changed files with 1,700 additions and 693 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
*.bat
*.log
*.lnk
*.aps
**/msvc/Debug*
**/msvc/Release*
**/msvc/Tests
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# ReGameDLL_CS [![Download](https://camo.githubusercontent.com/0c15c5ed5da356288ad4bb69ed24267fb48498f2/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f73316c656e74712f526547616d65444c4c5f43532e737667)](https://github.com/s1lentq/ReGameDLL_CS/releases/latest) [![Downloads](https://camo.githubusercontent.com/7eb895bf12d373df1d7c2bd2af3eb7d6328cdf6c02eee380fa93f81365c32d41/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f646f776e6c6f6164732f73316c656e74712f526547616d65444c4c5f43532f746f74616c3f636f6c6f723d696d706f7274616e74)]() [![Percentage of issues still open](http://isitmaintained.com/badge/open/s1lentq/ReGameDLL_CS.svg)](http://isitmaintained.com/project/s1lentq/ReGameDLL_CS "Percentage of issues still open") [![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) <img align="right" src="https://cloud.githubusercontent.com/assets/5860435/20008568/b3623150-a2d3-11e6-85f3-0d6571045fc9.png" alt="Counter-Strike 1.6 GameDLL" />
# ReGameDLL_CS [![GitHub release (by tag)](https://img.shields.io/github/downloads/s1lentq/ReGameDLL_CS/latest/total)](https://github.com/s1lentq/ReGameDLL_CS/releases/latest) ![GitHub all releases](https://img.shields.io/github/downloads/s1lentq/ReGameDLL_CS/total) [![Percentage of issues still open](http://isitmaintained.com/badge/open/s1lentq/ReGameDLL_CS.svg)](http://isitmaintained.com/project/s1lentq/ReGameDLL_CS "Percentage of issues still open") [![License: GPL v3](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) <img align="right" src="https://cloud.githubusercontent.com/assets/5860435/20008568/b3623150-a2d3-11e6-85f3-0d6571045fc9.png" alt="Counter-Strike 1.6 GameDLL" />
Reverse-engineered gamedll (mp.dll / Counter-Strike)

## What is this?
Expand Down
262 changes: 262 additions & 0 deletions dist/delta.lst
Original file line number Diff line number Diff line change
@@ -0,0 +1,262 @@
// structure name
// none == no conditional encode routine
// gamedll routine_name : before transmitting data, invoke the named function from the game .dll to reset fields as needed
// clientdll routine_name : same as above, except the routine is called via the client.dll

clientdata_t none
{
DEFINE_DELTA( flTimeStepSound, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( origin[0], DT_SIGNED | DT_FLOAT, 24, 1024.0 ),
DEFINE_DELTA( origin[1], DT_SIGNED | DT_FLOAT, 24, 1024.0 ),
DEFINE_DELTA( velocity[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( velocity[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),

DEFINE_DELTA( m_flNextAttack, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),

DEFINE_DELTA( origin[2], DT_SIGNED | DT_FLOAT, 24, 1024.0 ),
DEFINE_DELTA( velocity[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),

DEFINE_DELTA( ammo_nails, DT_SIGNED | DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( ammo_shells, DT_SIGNED | DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( ammo_cells, DT_SIGNED | DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( ammo_rockets, DT_SIGNED | DT_INTEGER, 10, 1.0 ),

DEFINE_DELTA( m_iId, DT_INTEGER, 5, 1.0 ),

DEFINE_DELTA( punchangle[2], DT_SIGNED | DT_FLOAT, 21, 8.0 ),
DEFINE_DELTA( flags, DT_INTEGER, 32, 1.0 ), // Cut to 3 bits?
DEFINE_DELTA( weaponanim, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( health, DT_FLOAT, 17, 1.0 ), // Cut # of bits?
DEFINE_DELTA( maxspeed, DT_FLOAT, 16, 10.0 ),
DEFINE_DELTA( flDuckTime, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( view_ofs[2], DT_SIGNED | DT_FLOAT, 10, 4.0 ),
DEFINE_DELTA( punchangle[0], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( punchangle[1], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( viewmodel, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( weapons, DT_INTEGER, 32, 1.0 ),

DEFINE_DELTA( pushmsec, DT_INTEGER, 11, 1.0 ),
DEFINE_DELTA( deadflag, DT_INTEGER, 3, 1.0 ),
DEFINE_DELTA( fov, DT_FLOAT, 8, 1.0 ),
DEFINE_DELTA( physinfo, DT_STRING, 1, 1.0 ),
DEFINE_DELTA( bInDuck, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( flSwimTime, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( waterjumptime, DT_INTEGER, 15, 1.0 ),
DEFINE_DELTA( waterlevel, DT_INTEGER, 2, 1.0 ),

DEFINE_DELTA( iuser1, DT_INTEGER, 3, 1.0 ),
DEFINE_DELTA( iuser2, DT_INTEGER, 6, 1.0 ),
DEFINE_DELTA( iuser3, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( iuser4, DT_INTEGER, 2, 1.0 ),

DEFINE_DELTA( vuser2[0], DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( vuser2[1], DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( vuser2[2], DT_FLOAT, 9, 1.0 ),

DEFINE_DELTA( vuser3[0], DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( vuser3[1], DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( vuser3[2], DT_FLOAT, 9, 1.0 ),

DEFINE_DELTA( vuser4[0], DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( vuser4[1], DT_FLOAT, 9, 1.0 ),

DEFINE_DELTA( fuser1, DT_FLOAT, 9, 1.0 ),
DEFINE_DELTA( fuser2, DT_FLOAT, 14, 1.0 ),
DEFINE_DELTA( fuser3, DT_FLOAT, 10, 1.0 )
}

entity_state_t gamedll Entity_Encode
{
DEFINE_DELTA( animtime, DT_TIMEWINDOW_8, 8, 1.0 ),
DEFINE_DELTA( frame, DT_FLOAT, 8, 1.0 ),
DEFINE_DELTA( origin[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( angles[0], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( angles[1], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( origin[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( origin[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( sequence, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( modelindex, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( movetype, DT_INTEGER, 4, 1.0 ),
DEFINE_DELTA( solid, DT_SHORT, 3, 1.0 ),
DEFINE_DELTA( mins[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( mins[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( mins[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),

DEFINE_DELTA( endpos[0], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( endpos[1], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( endpos[2], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( startpos[0], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( startpos[1], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( startpos[2], DT_SIGNED | DT_FLOAT, 13, 1.0 ),
DEFINE_DELTA( impacttime, DT_TIMEWINDOW_BIG, 13, 100.0 ),
DEFINE_DELTA( starttime, DT_TIMEWINDOW_BIG, 13, 100.0 ),

DEFINE_DELTA( weaponmodel, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( owner, DT_INTEGER, 5, 1.0 ),
DEFINE_DELTA( effects, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( eflags, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( angles[2], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( colormap, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA( framerate, DT_SIGNED | DT_FLOAT, 8, 16.0 ),
DEFINE_DELTA( skin, DT_SHORT | DT_SIGNED, 9, 1.0 ),
DEFINE_DELTA( controller[0], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[1], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[2], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[3], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( blending[0], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( blending[1], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( body, DT_INTEGER, 18, 1.0 ),
DEFINE_DELTA( rendermode, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( renderamt, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( renderfx, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( scale, DT_FLOAT, 16, 256.0 ),
DEFINE_DELTA( rendercolor.r, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.g, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.b, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( aiment, DT_INTEGER, 11, 1.0 ),
DEFINE_DELTA( basevelocity[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( basevelocity[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( basevelocity[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),

DEFINE_DELTA( iuser4, DT_INTEGER, 2, 1.0 )
}

entity_state_player_t gamedll Player_Encode
{
DEFINE_DELTA( animtime, DT_TIMEWINDOW_8, 8, 1.0 ),
DEFINE_DELTA( frame, DT_FLOAT, 8, 1.0 ),
DEFINE_DELTA( origin[0], DT_SIGNED | DT_FLOAT, 24, 32.0 ),
DEFINE_DELTA( angles[0], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( angles[1], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( origin[1], DT_SIGNED | DT_FLOAT, 24, 32.0 ),
DEFINE_DELTA( origin[2], DT_SIGNED | DT_FLOAT, 24, 32.0 ),
DEFINE_DELTA( gaitsequence, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( sequence, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( modelindex, DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( movetype, DT_INTEGER, 4, 1.0 ),
DEFINE_DELTA( solid, DT_SHORT, 3, 1.0 ),
DEFINE_DELTA( mins[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( mins[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( mins[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( maxs[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( weaponmodel, DT_INTEGER, 10, 1.0 ),
// DEFINE_DELTA( team, DT_INTEGER, 4, 1.0 )
// DEFINE_DELTA( playerclass, DT_INTEGER, 4, 1.0 )
DEFINE_DELTA( owner, DT_INTEGER, 5, 1.0 ),
DEFINE_DELTA( effects, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA( angles[2], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( colormap, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA( framerate, DT_SIGNED | DT_FLOAT, 8, 16.0 ),
DEFINE_DELTA( skin, DT_SHORT | DT_SIGNED, 9, 1.0 ),
DEFINE_DELTA( controller[0], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[1], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[2], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( controller[3], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( blending[0], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( blending[1], DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( body, DT_INTEGER, 9, 1.0 ),
DEFINE_DELTA( rendermode, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( renderamt, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( renderfx, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( scale, DT_FLOAT, 16, 256.0 ),
DEFINE_DELTA( rendercolor.r, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.g, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.b, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( friction, DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( usehull, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( gravity, DT_SIGNED | DT_FLOAT, 16, 32.0 ),
DEFINE_DELTA( aiment, DT_INTEGER, 11, 1.0 ),
DEFINE_DELTA( basevelocity[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( basevelocity[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( basevelocity[2], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( spectator, DT_INTEGER, 1, 1.0 )

DEFINE_DELTA( iuser4, DT_INTEGER, 2, 1.0 )
}

custom_entity_state_t gamedll Custom_Encode
{
DEFINE_DELTA( rendermode, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( origin[0], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( origin[1], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( origin[2], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( angles[0], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( angles[1], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( angles[2], DT_SIGNED | DT_FLOAT, 17, 8.0 ),
DEFINE_DELTA( sequence, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA( skin, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA( modelindex, DT_INTEGER, 16, 1.0 ),
DEFINE_DELTA_POST( scale, DT_FLOAT, 8, 1.0, 0.1 ),
DEFINE_DELTA( body, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( rendercolor.r, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.g, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( rendercolor.b, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( renderfx, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( renderamt, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( frame, DT_FLOAT, 8, 1.0 ),
DEFINE_DELTA_POST( animtime, DT_FLOAT, 8, 1.0, 0.1 )
}

usercmd_t none
{
DEFINE_DELTA( lerp_msec, DT_SHORT, 9, 1.0 ),
DEFINE_DELTA( msec, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( viewangles[1], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( viewangles[0], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( buttons, DT_SHORT, 16, 1.0 ),
DEFINE_DELTA( forwardmove, DT_SIGNED | DT_FLOAT, 12, 1.0 ),
DEFINE_DELTA( lightlevel, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( sidemove, DT_SIGNED | DT_FLOAT, 12, 1.0 ),
DEFINE_DELTA( upmove, DT_SIGNED | DT_FLOAT, 12, 1.0 ),
DEFINE_DELTA( impulse, DT_BYTE, 8, 1.0 ),
DEFINE_DELTA( viewangles[2], DT_ANGLE, 16, 1.0 ),
DEFINE_DELTA( impact_index, DT_INTEGER, 6, 1.0 ),
DEFINE_DELTA( impact_position[0], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( impact_position[1], DT_SIGNED | DT_FLOAT, 16, 8.0 ),
DEFINE_DELTA( impact_position[2], DT_SIGNED | DT_FLOAT, 16, 8.0 )
}

weapon_data_t none
{
DEFINE_DELTA( m_flTimeWeaponIdle, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_flNextPrimaryAttack, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_flNextReload, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_fNextAimBonus, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_flNextSecondaryAttack, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_iClip, DT_SIGNED | DT_INTEGER, 10, 1.0 ),
DEFINE_DELTA( m_flPumpTime, DT_FLOAT | DT_SIGNED, 22, 1000.0 ),
DEFINE_DELTA( m_fInSpecialReload, DT_INTEGER, 2, 1.0 ),
DEFINE_DELTA( m_fReloadTime, DT_FLOAT, 16, 100.0 ),
DEFINE_DELTA( m_fInReload, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( m_fAimedDamage, DT_FLOAT, 22, 1000.0 ),
DEFINE_DELTA( m_fInZoom, DT_INTEGER, 8, 1.0 ),
DEFINE_DELTA( m_iWeaponState, DT_INTEGER, 7, 1.0 )
DEFINE_DELTA( m_iId, DT_INTEGER, 5, 1.0 )
DEFINE_DELTA( fuser1, DT_SIGNED | DT_FLOAT, 22, 1000.0 ),
DEFINE_DELTA( fuser2, DT_SIGNED | DT_FLOAT, 22, 128.0 ),
DEFINE_DELTA( fuser3, DT_SIGNED | DT_FLOAT, 22, 128.0 ),
DEFINE_DELTA( iuser1, DT_SIGNED | DT_INTEGER, 16, 128.0 )
}

event_t none
{
DEFINE_DELTA( entindex, DT_INTEGER, 11, 1.0 ),
DEFINE_DELTA( bparam1, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( bparam2, DT_INTEGER, 1, 1.0 ),
DEFINE_DELTA( origin[0], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( origin[1], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( origin[2], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( fparam1, DT_FLOAT | DT_SIGNED, 20, 100.0 ),
DEFINE_DELTA( fparam2, DT_FLOAT | DT_SIGNED, 20, 100.0 ),
DEFINE_DELTA( iparam1, DT_INTEGER | DT_SIGNED, 18, 1.0 ),
DEFINE_DELTA( iparam2, DT_INTEGER | DT_SIGNED, 18, 1.0 ),
DEFINE_DELTA( angles[0], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( angles[1], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( angles[2], DT_SIGNED | DT_FLOAT, 26, 8192.0 ),
DEFINE_DELTA( ducking, DT_INTEGER, 1, 1.0 )
}
4 changes: 2 additions & 2 deletions dist/game.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ mp_free_armor "0"
// 1 - Affects teammates (default behaviour)
//
// Default value: "1"
mp_team_flash 1
mp_team_flash "1"
// Players can receive all other players text chat, team restrictions apply.
// 0 - disabled (default behaviour)
Expand Down Expand Up @@ -566,4 +566,4 @@ mp_freezetime_duck "1"
// 1 - enabled (default behaviour)
//
// Default value: "1"
mp_freezetime_jump "1"
mp_freezetime_jump "1"
3 changes: 3 additions & 0 deletions regamedll/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,9 @@ set(SHARED_SRCS
"public/FileSystem.cpp"
"public/interface.cpp"
"public/MemPool.cpp"
"public/MemPool.cpp"
"public/tier0/dbg.cpp"
"public/tier0/platform_posix.cpp"
)

set(GAMEDLL_SRCS
Expand Down
7 changes: 6 additions & 1 deletion regamedll/dlls/bot/cs_bot_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -630,11 +630,15 @@ void CCSBotManager::ServerCommand(const char *pcmd)
{
CONSOLE_ECHO("Ambiguous\n");
}
else
else if (found)
{
CONSOLE_ECHO("Current place set to '%s'\n", found->GetName());
SetNavPlace(found->GetID());
}
else
{
CONSOLE_ECHO("Error - place name '%s' no exists in phrases BotChatter.db\n", msg);
}
}
}
else if (FStrEq(pcmd, "bot_nav_toggle_place_mode"))
Expand Down Expand Up @@ -1448,6 +1452,7 @@ void CCSBotManager::SetLooseBomb(CBaseEntity *bomb)
if (bomb)
{
m_looseBombArea = TheNavAreaGrid.GetNearestNavArea(&bomb->pev->origin);
DbgAssert(m_looseBombArea); // TODO: Need investigation and find out why it cannot find nearest area for a lost bomb, just catch it
}
else
{
Expand Down
2 changes: 1 addition & 1 deletion regamedll/dlls/bot/cs_bot_pathfind.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1294,7 +1294,7 @@ CCSBot::PathResult CCSBot::UpdatePathMovement(bool allowSpeedChange)
if (IsOnLadder())
Jump(MUST_JUMP);

assert(m_pathIndex < m_pathLength);
Assert(m_pathIndex < m_pathLength);

// Check if reached the end of the path
bool nearEndOfPath = false;
Expand Down
1 change: 0 additions & 1 deletion regamedll/dlls/bot/cs_bot_update.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -437,7 +437,6 @@ void CCSBot::Update()
}
else
{
const int dada = offsetof(CCSBot, m_visibleEnemyParts);
// check LOS to current enemy (chest & head), in case he's dead (GetNearestEnemy() only returns live players)
// note we're not checking FOV - once we've acquired an enemy (which does check FOV), assume we know roughly where he is
if (IsVisible(m_enemy, false, &m_visibleEnemyParts))
Expand Down
9 changes: 7 additions & 2 deletions regamedll/dlls/bot/states/cs_bot_hunt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,15 @@ void HuntState::OnUpdate(CCSBot *me)
{
if (!me->IsRogue() && me->CanSeeLooseBomb())
{
CNavArea *looseBombArea = TheCSBots()->GetLooseBombArea();

// if we are near the loose bomb and can see it, hide nearby and guard it
me->SetTask(CCSBot::GUARD_LOOSE_BOMB);
me->Hide(TheCSBots()->GetLooseBombArea());
me->GetChatter()->AnnouncePlan("GoingToGuardLooseBomb", TheCSBots()->GetLooseBombArea()->GetPlace());
me->Hide(looseBombArea);

if (looseBombArea)
me->GetChatter()->AnnouncePlan("GoingToGuardLooseBomb", looseBombArea->GetPlace());

return;
}
else if (TheCSBots()->IsBombPlanted())
Expand Down
2 changes: 1 addition & 1 deletion regamedll/dlls/bot/states/cs_bot_idle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ void IdleState::OnUpdate(CCSBot *me)
}
}

assert((0, "A CT bot doesn't know what to do while the bomb is planted!\n"));
DbgAssert(!"A CT bot doesn't know what to do while the bomb is planted!\n");
}

// if we have a sniper rifle, we like to camp, whether rogue or not
Expand Down
Loading

0 comments on commit a793d77

Please sign in to comment.