Commit Graph

459 Commits

Author SHA1 Message Date
Marco Cawthorne ff17dea01f
Initial work towards the NSWeapon class. Testing will happen in base/ under the NEW_INVENTORY define.
Comitting this early to ensure nothing breaks and it'll co-exist.
2022-07-25 09:31:37 -07:00
Marco Cawthorne bda01e0f0f
Shared: NSLog should just take whatever N args 2022-07-20 16:48:41 -07:00
Marco Cawthorne df738da436
Get rid of src/gs-entbase/shared/{baseentity.h,env_sprite.h} 2022-07-20 16:38:12 -07:00
Marco Cawthorne 30b4007894
Get rid of src/gs-entbase/baseentity.h 2022-07-20 16:33:52 -07:00
Marco Cawthorne 197ce20c31
BotLib: Start making use of some of NSNavAI 2022-07-20 16:27:24 -07:00
Marco Cawthorne 356319a7b7
NSVehicle, NSPhysicsEntity get Save/Restore methods 2022-07-19 15:49:35 -07:00
Marco Cawthorne 2a220fb331
Move base classes out of gs-entbase. This evolution only happened because classes such as CBaseMonster that once existed were replaced and it grew from there.
Tweak g_developer prints for scripted_sequences.
2022-07-19 15:22:15 -07:00
Marco Cawthorne dc1cbc5da8
NSMonster: add InSequence() method. Fix scripted sequences.
PMove: use self.mins instead of PHY_HULL_MINS when testing friction.
disable friction for monsters for now, as it can break some scripted sequences.
2022-07-18 11:32:18 -07:00
Marco Cawthorne d7418151f0
Client: Disable some expensive routines when paused. 2022-07-18 10:02:04 -07:00
Marco Cawthorne 878df0941e
Cleanup for some CGameRules method types. Moved some Util_ functions into their own file. 2022-07-16 15:11:33 -07:00
Ivan Kukush e3fcc1f57f PMove: add a bunch of comments so peole would be aware of issues/limitations 2022-07-16 00:19:31 +03:00
Ivan Kukush 9455596a3a PMove: make sv_maxspeed actually controlls players speed 2022-07-16 00:17:54 +03:00
Ivan Kukush ac0e739170 PMove: swap heavy and light gasping sounds with each other 2022-07-16 00:14:06 +03:00
Marco Cawthorne b06544aacc
PMove: crouching will no longer affect your movement underwater. noclip and crouching will no longer adjust the camera view and player bbox. 2022-07-14 21:38:54 -07:00
Marco Cawthorne 2f8b36c499
Get rid of pmove_water.qc and all that. 2022-07-14 21:29:53 -07:00
Marco Cawthorne 5ad849697e
Forgot to remove this define in pmove 2022-07-14 21:09:18 -07:00
Marco Cawthorne 93ba8c6cc9
Shared: Clean up some of the player_pmove code. Games can now via macros define some properties without overriding a method. 2022-07-14 21:02:31 -07:00
Marco Cawthorne 220b424e33
Fix some misc Damage_Apply calls in really old parts of the code. Add more useful PlayerConnect/PlayerDisconnect methods into the base gamerules. 2022-07-14 18:04:11 -07:00
Marco Cawthorne 2735bd26f6
Server: Add cvar 'mp_foosteps', which only works in multiplayer. Hence the name. 2022-07-09 19:47:44 -07:00
Marco Cawthorne 66b09de431
Big commit fixing many regressions since crunch hit. env_sprite has been reworked.
multi_manager entities now behave correctly when calling themselves in MULTITHREADED mode.
Remove GS_RENDERFX option. Too many entities rely on its functionality anyway.
Fixed some rendermode behaviour - ladders will no longer be visible.
You can now see the playermodel (and no longer the viewmodel) in mirrors.
Fixed a lot of warnings.
2022-07-07 09:10:14 -07:00
Marco Cawthorne 5691fe518f
prop_rope: Minor performance boost. Add cvar rope_maxsegments. 2022-06-27 12:16:11 -07:00
Marco Cawthorne e7339b124e
NSRenderableEntity: Use the new addlight for RFX_Q2PULSE. Needs engine version bump. 2022-06-27 08:31:41 -07:00
Marco Cawthorne d1a90e9aa4
NSClientPlayer: Allow weapon input when in intermission & in vehicle, so the intermission end can get triggered. 2022-06-20 11:45:50 -07:00
Marco Cawthorne c996986631
prop_vehicle_driveable: respect clipvehicle 2022-06-16 23:04:26 -07:00
Marco Cawthorne 241c94368f
vguilib: only block inputs to engine if a widget successfully took a keypress into account 2022-06-16 21:57:53 -07:00
Marco Cawthorne 24c869d9aa
Client: Make sure we're respecting .viewzoom of a target that we spectate in first-person. 2022-06-09 16:46:28 -07:00
Marco Cawthorne a7d7dcd9ee
Change the last commit by turning this into an NSMonster specific function instead. 2022-06-08 17:41:02 -07:00
Marco Cawthorne 80099317cb
Entity_FindClosest: Don't return any entity of class "player" if their health is equal or below 0. 2022-06-08 17:35:56 -07:00
Marco Cawthorne 460eec7f76
PMoveCustom_: Check for MOVETYPE_NONE and disable any further interaction. 2022-06-08 11:39:28 -07:00
Marco Cawthorne 6982043380
Added NSInteractiveSurface. Make voting display which bindings to press for yes/no. 2022-06-04 14:09:50 -07:00
Marco Cawthorne d303ef9741
PropData: Respect fadetime for breakmodels. 2022-06-02 14:35:52 -07:00
Marco Cawthorne a463498f60
Huge cleanup. Add initial code for the revamped material definition system. 2022-06-01 17:38:52 -07:00
Marco Cawthorne 643211efae
Add helper functions Entity_FindClosests(string classname) and Entity_SelectRandom(string classname) 2022-05-26 13:25:02 -07:00
Marco Cawthorne db97db6820
Menu-VGUI: Fix up, change Input() method to block input from other widgets 2022-05-24 13:04:48 -07:00
Marco Cawthorne bb2b7dbddf
NSClient: add method UpdateAliveCam()
UITextbox: Misc polish regarding text entry
GLSL: Detail pass support for some materials
2022-05-15 13:32:53 -07:00
Marco Cawthorne 1e0534c922
NSSpraylogo: Handle vid_reload's gracefully 2022-05-13 11:41:33 -07:00
Marco Cawthorne 38f6996940
PMove: Fix typos that caused shenanigans. 2022-05-12 20:42:09 -07:00
Marco Cawthorne 6653d18417
Forgot to add these files (NSClient/Player/Spectator) 2022-05-11 13:18:02 -07:00
Marco Cawthorne 25c54af62c
Spring cleaning part one. 2022-05-11 12:49:04 -07:00
Marco Cawthorne a039a69dd3
Ultimately remove the deprecated old class names for base entities. 2022-05-10 15:01:40 -07:00
Marco Cawthorne 77c3cf4e10 Further fixes for OpenXR 2022-05-08 11:28:33 -07:00
Marco Cawthorne 9e0f93c796
Initial support for OpenXR. Remember to side-load the openxr plugin and set _pext_vrinputs to 1. 2022-05-07 17:58:22 -07:00
Marco Cawthorne 17611b7d38
PMove: Move some things around a bit. 2022-05-01 22:04:40 -07:00
Marco Cawthorne 70c2b43ff3
PMove: check for infokey 'autojump'... 2022-05-01 19:44:22 -07:00
Marco Cawthorne 594261cf7a
PMove: change default view offset to [0,0,28] 2022-05-01 15:57:10 -07:00
Marco Cawthorne e64e72d155
env_bubbles: Implementation. Should be complete.
NSIO: Add methods ReadBool(), SaveBool(), and PREDICTED_BOOL macro.
2022-04-30 20:18:56 -07:00
Marco Cawthorne cdfae26413
ambient_generic: Restructure and network more efficiently.
Client: add support for modelevent 1008 (CHAN_VOICE sound) and 1005 (plays Sentence)
2022-04-30 14:02:25 -07:00
Marco Cawthorne 92826b3e5a
Deprecate FL_NOATTACK, replace it with FL_FAKESPEC. 2022-04-28 16:25:51 -07:00
Marco Cawthorne ade1deb910
Revert "base_player: MakeTempSpectator() will now null think and nextthink."
This reverts commit 0c802295c3.
2022-04-28 14:52:38 -07:00
Marco Cawthorne 0c802295c3
base_player: MakeTempSpectator() will now null think and nextthink. 2022-04-28 12:34:01 -07:00
Marco Cawthorne 70f32c97a4
NSVehicle: Add method CanDriverCrouch() to deal with player physics restrictions. 2022-04-27 15:03:00 -07:00
Marco Cawthorne 2e43e671a4
Base_Player: Network movetype and solid together. 2022-04-26 14:10:17 -07:00
Marco Cawthorne 9030ad82d9
Base_Player: Make sure disconnected clients get removed from other clients.
Menu-FN: Clear Rich-presence when no longer in a game.
2022-04-26 11:22:12 -07:00
Marco Cawthorne 2d403202b9
Avoid use of infokeys to communicate whether or not a client is spectating. 2022-04-25 15:25:35 -07:00
Marco Cawthorne 607194957e
Player: Move UseUp/Down into the base_player class. Should now universally handle un-presses for all games. 2022-04-25 10:19:17 -07:00
Marco Cawthorne 7395b8d421
Gamerules: exception for friendlyfire when it comes to self
point_message: make messages appear through entities, as they may be translucent.
Fixed a minor warning.
2022-04-21 18:50:21 -07:00
Marco Cawthorne af6412e283
Networking improvements to NSEntity, NSRenderableEntity and NSSurfacePropEntity 2022-04-20 14:29:37 -07:00
Marco Cawthorne 8e15f04c38
prop_physics_multiplayer: Initial implementation. Developed with the ODE plugin in mind. 2022-04-20 10:44:59 -07:00
Marco Cawthorne bf00bfa60c
spectator: Several fixes to make spectating a bit more polished. Ignore fakespectators entirely, etc. 2022-04-18 15:53:15 -07:00
Marco Cawthorne a469c06fc8
Add 'surfaceparm projectile' support, so non-solid surfaces can
still react to tracelines and projectiles.
2022-04-13 16:58:42 -07:00
Marco Cawthorne 1b2f587599
Shared: Deprecate ClientRemove() over OnRemoveEntity, which will work on both Client and Server.
prop_vehicle_drivable: Add minor collision boxes to aid player physics
Fix some warnings.
2022-04-12 23:48:31 -07:00
Marco Cawthorne e79a2e9c2e
NSMonster: Add method bool CanCrouch(). Monsters will then attempt to crouch.
SoundDefs: Add support for distshader on Sound_PlayAt() calls.
2022-04-10 07:01:14 -07:00
Marco Cawthorne 6b1af093bb
NSMonster: use PMoveCustom_RunStandardPlayerPhysics instead of the engine, as it overrides
our hitcontentsmask. This is required for monster/bot clips.
Client: If an entity gets removed, ensure the .skeletonindex gets deleted.
2022-04-09 19:21:00 -07:00
Marco Cawthorne 2c79071514
base_player: MakeTempSectator() will now make sure modelindex of the target
is set to 0.
2022-04-08 12:58:23 -07:00
Marco Cawthorne a8c8938408
NSEntity: New method CreatedByMap(). Additional work towards more vehicle related
code in preparation for WASTES.
2022-04-06 16:21:07 -07:00
Marco Cawthorne 60e4853549
Clean up some misc warnings, switch over to internal bool type for some methods
in NSSurfacePropEntity, added Get/Set functions for MaxHealth.
Also bump BUILD_ENGINEREVISION to 6224 (minor crash fix upstream)
2022-04-02 09:21:49 -07:00
Marco Cawthorne e45987d65c
NSEntity: Added new methods based on GMod's API. More to follow. 2022-04-02 00:10:25 -07:00
Marco Cawthorne 8c3804a1bc
Make Client_InIntermission() a shared (Client/Server) function, add method 'InIntermission()' to CGameRules.
Tone down the intermission view movement, also tweak Spawn_SelectRandom() to find more points.
2022-03-29 15:20:52 -07:00
Marco Cawthorne 50312d500a
SurfaceProperties: Be more pedantic about what object can contain material
info in SurfData_Impact()
2022-03-28 19:01:29 -07:00
Marco Cawthorne 9e9d5b1832
env_fog_controller: Initial implementation. Fully shared entity, tested on
d2_coast_XX maps in Half-Life 2.
2022-03-23 11:05:35 -07:00
Marco Cawthorne 750bb413e9
prop_rope: Now a shared (client/server) entity instead of just client. Will
now respect parenting so you can have very dynamic rope attachments in
the world.
2022-03-22 16:38:31 -07:00
Marco Cawthorne 143a00e94e
Fix light_dynamic (static) from not spawning in CSQC. Add r_skipDiffuse to rtlight.glsl,
add SURF_PENETRATE, which will make bullets pass right through them when
BULLETPENETRATION is set. Go over and refactor a lot of base_client, player
and spectator code to facilitate both permanent and temporary spectators
better. Add experimental env_glow lens flare code. Fix material ID detection
bug for Q3 based BSPs. A couple helper functions were added to src/client/utils.cpp
but they are not yet final.
2022-03-17 21:05:47 -07:00
Marco Cawthorne 96f3a1224a
This is a massive change. Check the full msg here:
https://icculus.org/~marco/txt/nuclide_may2022.txt
2022-03-15 19:33:11 -07:00
Marco Cawthorne ae85529f95
Add pmodel attributes to the base player class. 2022-03-13 17:01:18 -07:00
Marco Cawthorne 0fc52f726d
BotLib now responds to 'alert' flagged sounds as well. Also added a cooldown
timer so we don't call alerts too often.
2022-03-11 14:00:44 -08:00
Marco Cawthorne 6fb067eed3
My name has changed, so an update to the copyright to reflect it. 2022-03-11 11:40:43 -08:00
Marco Cawthorne ce02de7eff
Physics_InputPostMove: Unset FROZEN _after_ physics frame... 2022-03-03 23:32:33 -08:00
Marco Cawthorne d8a8f07432
Client: make sure customphysics is set 'Empty' on monsters, clients 2022-03-03 23:31:59 -08:00
Marco Cawthorne 93124fa6de
base_player: Add Death() method that'll let the client know when to render
the 'Deathcam'. Also add the mentioned UpdateDeathcam().
2022-03-02 20:37:40 -08:00
Marco Cawthorne 6db98c88aa
BotLib: Add support for goalitems. These may include objectives for things
like CTF - flag your game-mode entities as either .botinfo BOTINFO_TEAM_GOALITEM
or BOTINFO_TEAM_GOALCAPTURE and BotLib will try to figure out what to do.
2022-03-02 09:17:57 -08:00
Marco Cawthorne ee2d3f6b3f
SoundDef: add 'pitch' support to Sound_PlayAt(), the pointsound builtin does
support pitch on FTEQW but it's not advertised in the extensions .qc
2022-03-02 09:14:02 -08:00
Marco Cawthorne a687d7b330
Various tweaks to documentation inside the codebase, more verbose general
information prints to console to aid non-devs in sending bug reports and
finding other issues. Updates to some of the GLSL. Minor material fixes.
2022-02-23 01:17:05 -08:00
Marco Cawthorne 8cb4c35e23
Remove SendFlags with constants from NSEntity and peers, make full use
of EvaluateEntity() to decide which attributes to send network updates of.
2022-02-18 00:30:24 -08:00
Marco Cawthorne 1d9ade7319
NSEntity: Add ClientRemove() method so sub-classes can control what happens
when a SSQC ent representation is removed from the client.
prop_vehicle_drivable: All sorts of tweaks, lots subject to change.
VGUI elements now get a callback when the resolution gets resized, so they
get a chance to reposition themselves.
Deprecate function ClientGame_EntityRemove().
2022-02-17 22:16:35 -08:00
Marco Cawthorne bcf9e2e758
Cleaning up some warnings. 2022-02-01 13:37:21 -08:00
Marco Cawthorne eb3eb567ca
Shared: nil out the base_client predraw. Get rid of the .pitch attribute of
base_player. Fix some angle networking typos.
2022-02-01 09:33:28 -08:00
Marco Cawthorne a3a5f9d626
Client: Some fixes for handling player/spectator classes, both share now the
same parent class on both client and server. Fix crash with spectators and
input-frame overrides. Add 'additive' command to fontdefs.
2022-01-31 17:38:01 -08:00
Marco Cawthorne e11465018f
Client: Allow base_player and spectator classes to override CSQC_Input_Frame
with a new method: ClientInputFrame.
2022-01-31 15:31:07 -08:00
Marco Cawthorne 578da4a779
Add VGUI_Active() which returns whether or not we're drawing VGUI elements,
add SNDFL_ALERTS to sound shaders, which will alert enemy AI of suspicious
behaviour, fix a health-setting bug in NSSurfacePropEntity and remove
playerslot check in item_pickup from base/
2022-01-28 16:02:00 -08:00
Marco Cawthorne 2c80a9f9ff NSSurfaceProp/PropData: Add support for breakable_skin. When a prop 'dies'
it doesn't necessarily have to disappear, it can change its material to one
of your choosing.
2022-01-28 06:53:32 +01:00
Marco Cawthorne 06d07738b6
Clean up the base classes, get rid of having to manually include the entbase
defs.h for the respective progs.
2022-01-20 16:23:29 -08:00
Marco Cawthorne 9e2b89e386
NSEntity: BBox will now account for rotation whenever SetModel() is used. 2022-01-20 12:30:53 -08:00
Marco Cawthorne 02c2ff7be5
env_glow: Add 'rotate' key to rotate the sprite/material by X degree amount 2022-01-07 17:04:43 -08:00
Marco Cawthorne 52dfde0cf1
Sound: Add Sound_PlayLocal() which is a 'sound shader' analogue to to
localsound()
2022-01-07 13:46:16 -08:00
Marco Cawthorne 749424aa84
NSMonster: Add support for actions (used in e.g. HLMDL) to query which seq
to play. This will be expanded shortly in-engine to support more formats...
2022-01-06 19:27:08 -08:00
Marco Cawthorne 9d4d7afdcd
Big overhaul of momentary_door, momentary_rot_button... now onto the last
entity until Hazard Course is fully functional from beginning to end.
2022-01-04 21:54:42 -08:00
Marco Cawthorne f2e44b24fb
Add platform/base_sound.pk3, move base sound shaders in there. Add misc/null
and misc/missing PCM samples for fallback.
2021-12-18 15:06:37 -08:00
Marco Cawthorne 6ec29e9985
SurfData_IDtoImpact: Fix IMPACT_METAL lookup 2021-12-17 21:23:30 -08:00
Marco Cawthorne c2e4050bae
Replace CSQC_Parse_Damage with our own, add EV_DAMAGE. Make sure trigger_hurt
respects the 'damagetype' field. Add CSQC_UpdateSeat to make querying of
the current player seat easier (splitscreen).
2021-12-17 18:20:30 -08:00
Marco Cawthorne 8075616d6d
SurfaceProperties: We were missing a few material ID lookups for GoldSrc
regarding impacts.
2021-12-16 13:12:44 -08:00