Raised This Month: $51 Target: $400
 12% 

[HL2DM] Dynamic NPC Spawner


Post New Thread Reply   
 
Thread Tools Display Modes
PAL-18
AlliedModders Donor
Join Date: Jul 2010
Old 07-12-2012 , 20:26   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #21

Quote:
Originally Posted by morgunfreeman View Post
Really would like to have this plugin working but it doesn't work with Linux Server. Pretty good about following instructions and it all compiled right and I got the .cfg's configured and even was able to create spawn points in map but waited and nothing happens even after I z_enabled.

??????????????????
I have the same problem. Everytime i do z_addspawn in console, im told:
Unknown command: z_addspawn
PAL-18 is offline
Retsnom
Junior Member
Join Date: May 2011
Old 08-05-2012 , 18:24   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #22

Quote:
Originally Posted by PAL-18 View Post
I have the same problem. Everytime i do z_addspawn in console, im told:
Unknown command: z_addspawn
I am running this on an Age of Chivalry server and it has been quite challenging because it is a free independent HL2 Mod so not everything is structured the same game and file wise.

I have gotten this to work on a linux but it is not consistently working specially when a map rotates out. This, Unknown command: z_addspawn will show up in your console sometimes but I have found that the spawn points do get placed there. This plugin will write a cfg folder with a spawn cfg per map under your server cfg file.

Here is a list of bugs that I have not been able to overcome and some maybe because I am using it on an HL2 Mod Age of Chivalry;

1. Plugin seems to work randomly in that I have to reboot the server to get it to work then a map will rotate out and it will not work again.

2. Not all populations will spawn, all the time or on command while sometimes the work fine.

3. Dead Npc bodies do not fade or disappear, adding to graphic lag in FPS after the bodies start to accumulate.

4. Manhacks when they spawn, just fly straight up, hit skybox and explode.

5. All NPCs die on one hit. Age of Chivalry is a first person melee game, so not sure if that is an issue.

6. Most NPCs do little to no damage to players, poison zombies thrown head crabs do no damage then those headcrabs, once thrown do nothing.

7. Sometimes the cvars will work on the fly and sometimes they will stop working along with the plugin.

Ok now I will post up some of my attemps to fix some issues. Here is a list of NPC settings I have found. Again, sometimes they work and sometimes they do not. I have tried to place this in the server.cfg but not sure why it didn't work and I will test placing these commands into the individual cfg/(map folder)/zombiespawns.cfg or maybe I will add an autoexec.cfg in that folder. Any help on correct location and syntax of these commands would be greatly appreciated.

Quote:
//------------------------Zombie settings-----------------------------------
z_enabled 1 //0/1 Enabled or disable the plugin.

z_population "" // Chooses the population from which NPCs are spawned.
// default = fastzombies
// headcrab = headcrabs, headcrab_poison, headcrab_fast
// zfull = zombie. fastzombie, poisonzombie, zombie_torso
// antlion = antlion
// antloinguard = antlionguard
// manhack = manhack
// vortigaunt = vortigaunt
// war = headcrab_fast, headcrab_poison, fastzombie, poisonzombie, zombie_torso, antlion, manhack, vortigaunt

z_frequency "" // Chooses the frequency of which NPCs are spawned.
// default = fast +100 (default war)
// havok = medium +100 (headcrab war)
// ant1 = medium + 25 (antlion battle)
// antg = slow +1 (antlionguard or one npc every 5 min)
// vort = medium +20 (vortiguant antlion zombie war)
// manhack = fast +50 (manhack, vort, antlion, zombie)
//z_addspawn This is the cvar to enter into console to place npc spawnpoints

//Zombie Damage Settings
//Antlion
sk_antlion_health 65
sk_antlion_air_attack_dmg 35
sk_antlion_jump_damage 25
sk_antlion_swipe_damage 25
ent_fire npc_antlion addoutput "ondeath kill"
ent_fire npc_antlion setrelationship "player d_ht 99"

//Antlionguard
sk_antlionguard_dmg_charge 50
sk_antlionguard_dmg_shove 50
sk_antlionguard_health 200
ent_fire npc_antlionguard addoutput "ondeath kill"
ent_fire npc_antlionguard setrelationship "player d_ht 99"

//Headcrabs
sk_headcrab_fast_health 15
sk_headcrab_health 15
sk_headcrab_melee_dmg 20
sk_headcrab_poison_health 20
sk_headcrab_poison_npc_damage 20
ent_fire npc_headcrab addoutout "ondeath kill"
ent_fire npc_headcrab_poison addoutput "ondeath kill"
ent_fire npc_headcrab setrelationship "player d_ht 99"
ent_fire npc_headcrab_poison setrelationship "player d_ht 99"

//Manhack
sk_manhack_health 15
sk_manhack_melee_dmg 20
sk_manhack_v21
ent_fire npc_manhack addoutput "ondeath kill"
ent_fire npc_manhack setrelationship "player d_ht 99"

//Vortigaunt
sk_vortiguant_armor_charge 30
sk_vortiguant_armor_charge_per_token 5
sk_vortiguant_dmg_claw 25
sk_vortiguant_dmg_rake 35
sk_vortiguant_dmg_zap 40
sk_vortiguant_health 100
sk_vortiguant_vital_antlion_worker_dmg 0.2
sk_vortiguant_zap_range 25
ent_fire npc_vortiguant addoutput "ondeath kill"
ent_fire npc_vortiguant setrelationship "player d_ht 99"

//Zombie
sk_zombie_dmg_both_slash 35
sk_zombie_dmg_one_slash 25
sk_zombie_health 75
sk_zombie_poison_dmg_spit 35
sk_zombie_poison_health 80
ent_fire npc_fastzombie addinput "sethealth 100"
ent_fire npc_fastzombie addoutput "ondeath kill"
ent_fire npc_zombie addoutout "ondeath kill"
ent_fire npc_zombie_poison addoutput "ondeath kill"
ent_fire npc_zombie setrelationship "player d_ht 99"
ent_fire npc_zombie_poison setrelationship "player d_ht 99"

//npc_destroy_unselected - Destroys all the NPCs not currently specified.
//npc_kill [npcname] - Kills specified NPC, or NPC currently under the cursor if none specified.

//------------------------------------end of zombie settings----------------------------
Other than this I am at a loss as to the inconsistency of this plugin. I love the concept and maybe it is just me and how I have it config. Again any help on locations of npc config, syntax of npc commands, and getting this to work consistently would be great!

When it does work it is awesome!
Retsnom is offline
Retsnom
Junior Member
Join Date: May 2011
Old 08-09-2012 , 05:33   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #23

UPDATE: After tons of experimentation I have gotten most of the things I wanted to work to work. I am still adjusting health and damages but I still cannot figure out how to make the dead NPCs to fade and none of theses "ent_fire npc_fastzombie ondeath destroy" work for either destroy or kill so I am looking for a solution.


Here is the latest server.cfg


//----------------Zombie CFG------------------------------
//zombie
sk_zombie_health "100"
sk_zombie_dmg_one_slash "25"
sk_zombie_dmg_both_slash "35"
sk_zombie_poison_health "100"
sk_zombie_poison_dmg_spit "35"
ent_fire npc_fastzombie sethealth 100
ent_fire npc_fastzombie ondeath destroy
ent_fire npc_poisonzombie ondeath destroy
ent_fire npc_zombie ondeath destroy
ent_fire npc_zombie_poison ondeath destroy
//Vortigaunt
sk_vortigaunt_armor_charge "30"
sk_vortigaunt_armor_charge_per_token "5"
sk_vortigaunt_health "150"
sk_vortigaunt_dmg_claw "25"
sk_vortigaunt_dmg_rake "0"
sk_vortigaunt_dmg_zap "25"
sk_vortigaunt_zap_range "25"
sk_vortigaunt_vital_antlion_worker_dmg "0.2"
ent_fire npc_vortiguant ondeath destroy
//Manhack
sk_manhack_health "25"
sk_manhack_melee_dmg "10"
sk_manhack_v2 "1"
//Icthyosaur
sk_ichthyosaur_health "50"
sk_ichthyosaur_melee_dmg "20"
//Headcrab
sk_headcrab_health "20"
sk_headcrab_fast_health "20"
sk_headcrab_poison_health "20"
sk_headcrab_melee_dmg "5"
sk_headcrab_poison_npc_damage "10"
sk_headcrab_poison_health "25
ent_fire npc_headcrab ondeath destroy
ent_fire npc_headcrab_poison ondeath destroy
ent_fire npc_headcrab_black setdamage 10
ent_fire npc_headcrab_poison setdamage 10
ent_fire npc_headcrab_black ondeath destroy
SetRelationship npc_headcrab_black player d_ht 99
//Antlion
sk_antlion_health "120"
sk_antlion_swipe_damage "20"
sk_antlion_jump_damage "25"
sk_antlion_air_attack_dmg "25"
ent_fire npc_antlion ondeath destroy
//Antlionguard
sk_antlionguard_dmg_charge "75"
sk_antlionguard_dmg_shove "50"
sk_antlionguard_health "400"
ent_fire npc_antlionguard ondeath destroy
//---------------------End Zombie CFG---------------------------------
Retsnom is offline
thegameeer
Junior Member
Join Date: Mar 2013
Old 03-11-2013 , 11:48   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #24

Can anyone help me with this plugin? it doesn't seem to work for me. I've set up the population and frequencies but zombies don't spawn.
thegameeer is offline
Incom
New Member
Join Date: May 2013
Old 06-26-2013 , 20:56  
Reply With Quote #25

The plugin does not work properly on the new version of the game (not SteamPipe):

Protocol version 24
Exe version 1.0.0.43 (hl2dm)
Exe build: 12:41:03 Mar 29, 2013 (5256) (320)

Server: Linux Ubuntu 10.10
Version SourceMod: 1.6.0-dev+3900
Version MMSource: 1.10.0-dev

The logs SourceMod writes:
L 06/26/2013 - 05:41:57: [SM] Native "GetEntPropVector" reported: Property "m_vecOrigin" not safe to access (entity 22/soundent)
L 06/26/2013 - 05:41:57: [SM] Displaying call stack trace for plugin "zombies.smx":
L 06/26/2013 - 05:41:57: [SM] [0] Line 622, zombies.sp :: Occupied ()
L 06/26/2013 - 05:41:57: [SM] [1] Line 657, zombies.sp :: SpawnZombie ()
L 06/26/2013 - 05:41:57: [SM] [2] Line 738, zombies.sp :: PluginLifeTimer ()

Please help to correct errors in the plugin. Thank you

Can anybody help?

Does anyone of the scripters look at the code of this plugin

Last edited by thetwistedpanda; 07-07-2013 at 16:38. Reason: Merged bumps.
Incom is offline
Alienmario
Senior Member
Join Date: Aug 2013
Old 11-16-2013 , 19:58   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #26

You could try this, no guarantee it'll work though.
Attached Files
File Type: sp Get Plugin or Get Source (DynamicNPC.sp - 777 views - 14.7 KB)
Alienmario is offline
ToasterOven
Junior Member
Join Date: Aug 2020
Old 09-04-2020 , 09:35   Re: [HL2DM] Dynamic NPC Spawner
Reply With Quote #27

I know this is a 6 year old thread, but I noticed this is the only npc spawner plugin, and was wondering if anyone with more coding experience could somehow port this to tf2 (which has built in skeleton npc nextbots) only this time being able to be linked with cp capture transitions for szf and such, maybe even throw in npc health and attack customization as not all zf and szf servers have the same balance as of rn.

Thanks.

Last edited by ToasterOven; 09-04-2020 at 09:36.
ToasterOven is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 21:30.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode