branchsbox-gunfight/maincancel
854 Commits over 578 Days - 0.06cph!
Stub out player HUD setup, only enable hud gameobject if we're the local player
Made a few things on the PlayerController use RequireComponent so there's less setup
Refactor how viewmodels are made, to work in multiplayer
Fixed compile
GameManager -> Game, removed some useless code
Removed recoil pattern system (cool experiment, not something I want to use in practice)
Use GameObject references in WeaponDataResource, instead of dumb hack from months ago
Fixed weapon instantiation bugs
Align impact decals correctly instead of accounting for the 90 degree offset bug
Fix error spam from sound emitter
Add an access point for the player controller to influence recoil
Cleanup, add horizontal and vertical spread ranges
Add loop points to recoil patterns
https://files.facepunch.com/tony/1b2611b1/Zwf2E8V68x.png
https://files.facepunch.com/tony/1b2611b1/sbox-dev_9zVXae9zXk.mp4
Update style of recoil pattern UI, draw line with all points https://files.facepunch.com/tony/1b2611b1/z5ZQTeqnS5.png
Use recoil pattern in RecoilFunction
https://files.facepunch.com/tony/1b2611b1/sbox-dev_xaXurG5u7E.mp4 https://files.facepunch.com/tony/1b2611b1/CS5fvYwsxo.png
Add editor for designing recoil patterns
https://files.facepunch.com/tony/1b2611b1/rNGbSsl88U.mp4
Fixed not finding the ammo container
Move weapon functions into a separate gameobject on the weapon for organization
Refactor weapon abilities to be weapon functions, stats can be modified by weapon functions
Update camera animation code to use local bone transform, ty @aylaylay
https://files.facepunch.com/tony/1b2511b1/sbox-dev_iEfv2HkNNa.mp4
Don't overcomplicate stats
Add weapon stats system baseline
Add test code for local bone transform
Remove unused field from SoundEmitter
Add main menu, default scene is main menu, add play button
Add GameObject.PlaySound as a fire and forget way to play sounds on a gameobject (and have it follow the object)
Apply decal random rotation, spawn particles
Bullshit reloading system for now
Add GameObject.DestroyAsync extension
Add SurfaceComponent and GameObject.GetSurface extension method
Prefab updates
Get surface from weapon shoot trace, create impact effect gameobject from decal definition
https://files.facepunch.com/tony/1b2311b1/sbox-dev_M7K7YcLTh5.mp4
Use new particle for muzzle flash instead of legacy
Remove PlayerController.IsDucking
Maintain interpolated local position and rotation so we can just keep applying, add sliding state to vm
Apply local transform to viewmodel based on wish direction
Hook up slide anim and remove legacy stuff
Mechanics can override acceleration
Scale down wish input significantly while sliding
Can't slide/crouch while sliding
Expose HasAnTag accessor
ViewModel move_groundspeed cleared if we have the slide tag
Categorize base mechanic properties
Add Mechanic.ShouldBecomeaActive / Mechanic.ShouldBecomeInactive so mechanics can lock
Add basic sliding mechanic
Mechanic.IsActive is set properly by holding a list of active mechanics between updates
Player controller input refactor, let mechanics interrupt input (sprint dampening left-right movement)
Refactor, mechanics have tags which are cleared every frame, move sprint to a mechanic
Update DamageInfo
Work on getting camera bone animating for viewmodel
Block out player controller mechanics, eye height override, speed override, etc
Add muzzle flash prefab & util timed destroy component