branchwiseguys/main/Workingcancel
343 Commits over 153 Days - 0.09cph!
Fixed a double damage issue with bullets. Can now prevent double damage from hitbox + motor while also allowing a shooter to be assigned on C4 and so on, which only do server damage. So cops will shoot you if you hurt them with your C4 explosion, your C4 will actually do damage to the motor hit receiver, but your bullets won't. But bot and NPC bullets will.
Sort out client/server hit damage. Still need to test a bit more, maybe refactor a little.
Another rename for clarity
Rename IBulletShooter to IShooter
Updated C4 to simply throw on the server. Angle may be affected by lag if the player is turning their view while throwing.
Clean up warnings when in #CLIENT mode
Changed reloading to not fire from the client. Got rid of reload-specific methods as well and moved all reloading stuff out of the base HeldItem and into guns.
Update held item use methods
Call HeldItem DoUpdate from both client and server. Set deployedtime differently so we don't need the base DoUpdate method.
Info when you don't have space to take stuff from a dealer
Clear last damager info if they die. Refactored.
Decrease pistol max firing rate slightly
Adjusted melee so fists etc can actually reach beds to punch/hit them
When missions can't pay to bank account, they fall back to inventory, then ground drop.
Removed shadow on mission arrow
Disallow placing objects on building roof
Added another ghost NPC check
Drug Dealer AI fixes, and fixed bug where they could keep shooting after losing their target.
Drug dealers say when they stop following.
Working on Drug Dealer AI. Drug dealers now flee violence if they have no corp owner OR have a current follow target. Will help prevent using them for raids. Needs some fixes still.
Drug dealers stop following if they take damage
Dealers stop following if follow target is arrested, disconnects, enters a vehicle, or gets too far away (or dies, but that was already in)
Have dealers not crowd you out so much when following - they don't mind being up to 5m away now.
Made drug dealers easier to kill (less HP, less shooting accuracy)
Fixed climbable street lamps and simplified their colliders
Medikit uses notification instead of info. Less spammy as it doesn't block screen so much.
Added colliders to the shop signs
Adding logs and checks trying to detect the "ghost cops" bug
Commenting out "Skipping next input rate check" warning as real server builds seem to occasionally spike way down in framerate despite running fine 99% of the time, which causes unnecessary log spam.
Allow client s to set damage pre-init, since they do it on Deserialize
Don't arrest if you're dead (0HP). Should stop "ghost cops" arresting people
Add my CharacterHealth damage before init check back, just in case (trying to solve ghost cops)
- Added map icons for corp drug dealers.
- Refactored most map icons to use the same base prefab and a simple AddIcon method in Map.cs. Especially useful for classes that need a map icon where prefabs can't be assigned.
Match my code to project coding standards
Rewording dealer interactions for corps
Drug dealers now work for a corp, not an individual.
Cops now kill instead of arrest on maps with no prison (useful for testing).
Allow cyka blyat to work on maps with no units at all (allows testing on my test map)