I am using ents.create to spawn NPC's into the game, do I need to equip npc's with some sort of melee weapon? I spawn npc's and they can't hurt players, if you kill a zombie, the headcrab that falls off is able to hurt players, I don't understand whats going on..
I am still having no luck on getting NPC's I spawn with ents.Create() to actually damage players, any help would be greatly appreciated! :)
First:
[img]http://img543.imageshack.us/img543/6383/readrules.png[/img]
Second:
Got no clue what you mean .. if you want to spawn a NPC you need something like this
[lua]
ents.Create("npc_citizen")
ents:SetPos( Vector(X,Y,Z) )
ents:Spawn()
[/lua]
[highlight](User was banned for this post ("rage face reply/back seat moderating" - postal))[/highlight]
Yes that is correct, I am able to spawn NPC's but their attacks do not damage players. If I spawn a zombie the zombie's melee attacks do not damage the player, if the headcrab falls off the zombie the headcrab will damage the player.
Look how garry spawns them:
[url]http://glua.me/bin/?path=/gamemodes/sandbox/gamemode/commands.lua[/url]
Sorry, you need to Log In to post a reply to this thread.