The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
special forces attacking npc with karma < 0
Author Message
Berkley
Journeyman
*

Posts: 54
Likes Given: 28
Likes Received: 2 in 2 posts
Joined: Jul 2015
Reputation: 0



Post: #20
RE: special forces attacking npc with karma < 0
(02-17-2016 05:03 PM)Khaos Wrote:  The original post asked for rangers to attack monsters, not players. Also @SeeNewPlayer?! It should be @NPCSeeNewPlayer.

Using Forchars also checks <distanceyell> in characters. Just use FOR.

Just put this on your ranger's. Attach it in their core code or use events. Whichever you choose. Technically this is NOT what you asked for. If you get into more detail I can script what you originally wanted. You asked for Ranger's WITHIN Yell distance to attack for your char. This script works a bit different. This will fire off with a ranger in a sector that is not asleep. It will attack anything -800 or worse in karma and call for aid of other rangers within yell distance to attack that same target.

I think this is more what you were looking for. Add this via tspeech. When the NPC's hears a player yell for HELP. It will attack the first EVIL NPC within yell distance.

This can be refined more to store the players position and ranger's and only attack things within that distance. Though, we are getting awfully technical at that point.

Very nice! I think this works fine on my server. Many thanks for this.

Best regards, Lars
02-25-2016 04:12 AM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes Berkley's post
Post Reply 


Messages In This Thread
RE: special forces attacking npc with karma < 0 - Berkley - 02-25-2016 04:12 AM

Forum Jump:


User(s) browsing this thread: 2 Guest(s)