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
Criminal will flag you grey even if you are PK
Author Message
XuN
Sphere Developer
*****

Posts: 852
Likes Given: 102
Likes Received: 156 in 119 posts
Joined: Jul 2013
Reputation: 30



Post: #2
RE: Criminal will flag you grey even if you are PK
This is intended (OSI-like), you can override this with @NotoSend:

Code:
ON=@NotoSend
if (<IsEvil>) // If i'm evil
argn1 = 6 // my notoriety will be always RED regardless of anything else (criminal, etc), you can also add some checks here to send green notoriety for PK players in same guild, party, etc ... or even custom friend lists... whatever :)
endif


[FUNCTION IsMurderer] //tells if someone is PK.
return <qval (<kills> > <serv.MurderMinCount>) ? 1 : 0>

[FUNCTION IsEvil] // tells if someone is RED, because of being PK or any other factors.
if (<Region.Guarded> && <Region.tag0.red>)// red regions have reversed checks.
if (<IsMurderer>)
  return 0
endif
if (!<Brain>) // player
  if (<Karma> > <serv.PlayerKarmaEvil> )
   return 1
  endif
else
  if (<Karma> > 0 )
   return 1
  endif
endif
return 0 // Anything else is not red in this region, return false
endif
//Other regions
if (<IsMurderer>) //If I'm PK them i'm red, no more checks needed.
return 1
endif
if (<brain>) // special checks for npcs
if (<brain>==12 || <brain>==10) // brain_undead and brain_monster
  return <qval (<karma>< 0)?1:0> // are red if their karma is lower than 0
elseif (<brain>==11) // brain_berserk is always red
  return 1
elseif (<brain>==1) // brain_animal are red if karma is lower or equal to -800
  return <qval (<karma><=-800)?1:0>
endif
else //players
return <qval (<Karma> < <serv.PlayerKarmaEvil>)?1:0> // checking ini's setting for player's karma.
endif
return <qval (<Karma> <= -3000)?1:0> // everything else must have less than -3000 karma

I'll post an aditional function:

Code:
[FUNCTION IsNeutral]
if (<brain>)
if (<brain>==10 || <brain>==11) // undeads and monsters
  return <qval (<karma> < 0)?1:0>
elseif (<brain>==1) // animals
  return <qval (<karma> <= 100 )?1:0>
endif
else
return <qval (<Karma> < <serv.PlayerKarmaNeutral>) ?1:0>
endif
return <qval (<Karma> < 0) ?1:0>
(This post was last modified: 05-09-2015 04:52 PM by XuN.)
05-09-2015 04:50 PM
Find all posts by this user Like Post Quote this message in a reply
[+] 1 user Likes XuN's post
Post Reply 


Messages In This Thread
RE: Criminal will flag you grey even if you are PK - XuN - 05-09-2015 04:50 PM

Forum Jump:


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