Berkley 
Journeyman

Posts: 54
Likes Given: 28
Likes Received: 2 in 2 posts
Joined: Jul 2015
Reputation: 0
![]()
|
RE: special forces attacking npc with karma < 0
Perfect, many thanks for your help!!
i added this in my sphere_events_human.scp
[EVENTS e_Human_ConvInit]
ON=@NPCSeeNewPlayer
//ON=@NPCLookAtChar
// When a new person comes into range do something (attack them?)
forchars <serv.distanceyell>
if (<npc> && <brain> && <TITLE> == ranger)
ref1=<uid>
forchars <serv.distanceyell>
if (<karma> < -799)
ref1.attack <uid>
endif
endfor
endif
if (<npc> && <karma> < -799)
ref1=<uid>
forchars <serv.distanceyell>
if (<npc> && <brain> && <TITLE> == ranger)
ref1.attack <uid>
endif
endfor
endif
endfor
Now every Ranger i placed in game attacks every red (under 800 Karma) npc in near of the player. So Rangers can protect players automatically in special Areas.
Best regards, Lars
(This post was last modified: 01-31-2016 06:15 AM by Berkley.)
|
|
01-31-2016 05:25 AM |
|
|