Garry's Mod

Garry's Mod

Dynamic NPC Squads
Showing 1-10 of 13 entries
< 1  2 >
Update: 1 Aug @ 2:37pm

Big crash fix, don't do squad stuff with striders.
+lots of small tweaks.

Update: 31 Jul @ 4:22pm

Tweaks, potential crash fix

Update: 11 Jul @ 10:26pm

Small tweaks, fixes.

Update: 6 Jul @ 6:06pm

Let striders, helicopters, gunships join squads

Update: 21 Jun @ 12:13pm

Improve "Blacklisting" logic
Blacklisted/crashing npcs now call for backup, instead of doing nothing.

Added DYN_NPC_SQUADS.dynSquadTeams utility table.

Properly dissolve squads if any members hate eachother

+ misc small tweaks

Update: 18 May @ 2:05pm

Error stomp

Update: 11 May @ 12:40pm

Code cleanup + optimisations


Made autorun a loader.

OnEntityCreated optimisations/tweaks.
Returns early if :IsNPC() check fails.
Only creates one timer.simple.

Rework "idle/alert" logic a bit, to be more readable.

npc.DynamicNpcSquadsIgnore doesn't cancel the timer.

All assault/reinforce funcs now take priority variable.
0 priority is highest priority.

Made squads more likely to leave enclosed areas.

Update: 1 May @ 1:16pm

More polish
Wandering squad leaders will now "direct" their members away from other squads, meaning they'll spread out a bit more when wandering.

Fixed squads not using up assaultpoints when acquiring them
( npcs won't flood other squads with backup, backup will come as more of a trickle )

NPCs clear areas much more aggresively
( less redundant wandering back and fourth after a fight )

Improved compatibility a bit
( dynsquad prioritizes SetSquad/GetSquad over the squadname keyvalue )

Moved all "Yapping" logic to a new autorun file

Update: 26 Apr @ 7:27pm

Bug stomp

Update: 20 Apr @ 5:32pm

Rebels & vortigaunts now talk when they do dynsquad actions.
( And reply to eachother! )

Added the "Dynsquad Goal"
Basically a capture point.

Renamed convar
npc_dynsquads_dosquads to npc_dynsquads_enabled

Added convars:
npc_dynsquads_developer ( enables/disables debug info )
npc_dynsquads_dowandering ( idle npc wandering )
npc_dynsquads_doassaults ( idle npc reinforcing )
npc_dynsquads_yapping ( enables/disables the extra idle npc voicelines )

Massive optimisations.

Fixed duped squads not working properly.

Fixed npcs without weapons acting a bit too suicidal.

Polished the crap out of the "backup" system.
Added functions for devs to give "backup" points to npcs.
DYN_NPC_SQUADS.SaveReinforcePointAllNpcTeams( pos, filter )

See the new dynsquad_goal for a working example.

Npcs will now only call for backup when their squad is running into problems, losing health, members.

Added hooks
"dynsquads_blockmovement" Just blocks the dynsquad system from changing an npc's schedule.
"dynsquads_blocksquadthinking" Blocks all dynsquad thinking for one specific npc.

Fixed autorefresh breaking the script.