Garry's Mod

Garry's Mod

[VJ Base] Humanimal SNPCs: Part 1 - The Humanimal's [Update!]
1-10 van 40 items weergegeven
< 1  2  3  4 >
Update: 12 nov om 7:01

Update: 11 nov om 22:52

Libary Update
- Certain actions such as taunting or the ground slam attack add extra time delay to when the SNPC can charge.

- For the custom bonemerge function, I added the feature where you can apply a specific colour to the bonemerged model, though at its current state, it can only support a single colour.

- Added option to set the visibility of the original model for bonemerging to be visible.

- For the revive function, added a variable that stores the telegraph sound when respawning, and added a variable to enable/disable the spawn telegraph sound.

Update: 11 nov om 19:05

[Library Update]
- Ported dodge code from humanimal base into the library, and made it a bit more advanced, adding variables to set the forward, left, right, and backwards dodge animations, a variable to control the trace line obstruction check dist, and a variable to enable or disable forced velocity when dodging. Code will only play a dodge animation if one of the variables has a valid animation string in it, so if you only have one animation set for the forward animation, and set the variables setting the left, right and backwards animations, the code will automatically skip them and only ever play the forward animation.

- Added a small timer delay for taunting after hitting an enemy.

- Never forget enemy convar is handled in the library that is called within SNPC init.

Update: 9 nov om 18:30

General Stuff
- Minor optimizations.
- Improved ranged projectile code, where now the SNPCs will use the 'Line' fire method if an enemy is close, or if either the SNPC or enemy have a surface detected above them.
- Ranged arc trajectory is a little better.


Major Change
This change won't directly affect the average gmod player, but I've moved a lot of code into its own separate Lua file as its own library, where it contains a majority of new mechanics and features that can be easily used for new or current SNPCs.

Currently, my new Humanimal SNPCs I've been working on use this library format, which has made it much easier to update and maintain. I've tried my best to make the code readable and clean in case other users want to have a look at it, and use some of the code for their own SNPCs. To use the library, just put 'include('vj_base/extensions/uni.lua')' at the top of you SNPC's Lua init.

More functions and features are planned to be packed into the new library.

Current SNPC's using this base and their updates.
Humanimal [Warden]
- Added ground slam attack.
- Taunt on hit, and on killing a target.
- Rock throw range attack is tied to the material of the ground they are currently standing on.
- Proper landing on ground animation and sounds.
- Will shift to regular running to a more aggressive charge when pursuing an enemy.
- Majorly improved bullet ricochet system.
- Slightly dynamic ranged projectile trajectory. Straight if close, and arc if the enemy is far away.
- Water extinguishes fire.
- Will extinguish itself if on fire.
- Will locate and eat gibs to regain health.
- Gesture attacks.
- Can break down doors.
- Certain events can spawn small parasites. E.g, damaged or death.
- Fire cancels out parasite spawning.
- Properly handled visual effects applied to the player when hitting them.
- Code is much cleaner and readable.

Update: 20 okt om 0:53

- Updated post door break reaction anim code to accept table and string.

Update: 20 okt om 0:49

- Small fix.
- For door breaking, made the code accept both gesure and sequence anims, and corrected time lock when doing the door break anim.

Update: 20 okt om 0:33

- FIxed wrong convar assigned to the break door function.

Update: 19 okt om 5:37

- Newborns and young cicada's cannot borrow now.

Update: 19 okt om 5:30

- Optimized the handling of the cicada's bonemerged model, now shortened into one function for both applying the bonemerge to the SNPC on spawn and death model.

- New burrowing mechanic, where if on valid materials like dirt or grass, the Humanimal's will burrow underground to hide for a random period of time before popping back up.

- Changed timer for reviving to be from 1 - 180 second, cleaned up revive code a bit and added the chance the SNPC to remember the enemy that killed it when reviving.

- Small value changes and very minor optimizations to multiple functions.

- For retreating, optimized the function and made it more centered and robust.

- Very minor bone randomization.

- Fixed issue with error popping up if you spawned and quickly removed the SNPC in cases that causes them to flap or vibrate their wings.

- Bunch of small changes.

Update: 8 okt om 4:49

- Optimised and simplified the ranged projectile code.
- Lowered min distance for ranged attacks.
- Added chance for the Humanimals to find cover when alerted.
- Minor optimizations and tweaks along various functions.
- Hopefully improved most functions that force the SNPC to reposition or take cover.