let me explain a bit
Well, the tutorials I found never really told you how to target the player. I finally figured out how to do it, but it took a few extra steps to get the relationships to trigger. So here is how I got it to work:
- Insert an entity called logic_auto
- Have an output OnMapSpawn logic_relay trigger
- Insert a logic_relay
- Have an output OnTrigger logic_timer Enable
- Insert a Logic_timer
- Have an output OnTimer ai_relationship Apply Relationship
- Insert an ai_relationship
Subject: NPC_antlionguard
Target: !player
Start Active: Yes
Reciprical: No
- Insert an NPC (monster) and name it
- Make an output OnDeath Npc_maker spawn
- Make another output OnWake Npc_maker Enable
- Insert an npc_maker
- Make sure the NPC class matches the NPC spawned
- Insert Info nodes everywhere you want your NPC to navigate
and you are almost ready to GO
the npc will come after you now but cant damage you and if you shoud it 1 to its dead......
so we have to make rules like:
-How much health does the NPC have
-How much damage the NPC can cause to !player
for this we need to ad 2 things.....
- point_servercommand
- point_clientcommand
Name then both "client"
now we need to go to our logic_auto we need to add the folowing outputs.....
my output : onmapspawn
target : client
target input : command
parameter : sk_antlionguard_health 5000
delay : 1 second
my output : onmapspawn
target : client
target input : command
parameter : sk_antlionguard_dmg_shove 500
delay : 1 second
my output : onmapspawn
target : client
target input : command
parameter : sk_antlionguard_dmg_charge 500
delay : 1 second
now we have antlion guard with the folowing specs
Health 5000
damage to !player 500
the Best way for spawning NPC's are after the commands!(using a Trigger_multiple or a button that triggers the NPC_maker to spawn)
if an npc spawns earlier then the commands the NPC will have the standard values.......
causes no damage and is death in 1 hit
good luck and have fun



