Request/Question - always aggros npc
Forgive me if I am out of date on this but here is what I know:
Back when I was actively messing with the server, I learned that in order to make npc always aggro on a player regardless of a level (like lev 5 undead aggro on lev 50 players) you had to set their INT below 75. Which is a bit awkward and obscure and most people don't even know this. I know npc stats probably not used for much, but wouldn't it be better to change that and set it with proper npc Flag instead, like we do for Special Attacks? (http://wiki.eqemulator.org/p?NPC_Spe...tacks&frm=Main) Thank You! |
Could this ruletype help ?
Code:
RULE_INT(Aggro, IntAggroThreshold, 75) // Int <= this will aggro regardless of level difference. |
Yeah, but I think its sort of weird assigning it to a stat score rather than having a special attack flag.
|
Quote:
|
Quote:
|
Quote:
http://wiki.eqemulator.org/p?NPC_Spe...tacks&frm=Main |
This is a pretty basic change guys.
You'll need to add the special ability. Here's an example: Code:
common.h Code:
aggro.cpp That function is so abhorrent it deserves an award. |
How does this current rule fit into that ? Because I'm ok, with it so far.
Code:
RULE_BOOL(Aggro, UseLevelAggro, true) // Level 18+ and Undead will aggro regardless of level difference. (this will disable Rule:IntAggroThreshold if set to true) |
you would have to have pretty low intelligence to attack a a lvl 50 at lvl 5. maybe that's the reasoning? =p
|
Quote:
Thank You Coenxai! Would be great our devs would add this to the official source! ;) BTW the mob doesn't necessarily needs to be Undead ;) It can be any type of mob that's needs to be always aggro ;) |
Delete this post.
|
Quote:
|
Quote:
actually it would be better if Undead don't always aggro automatically - because you may want undead that don't aggro. (not all undead on live were always aggro - there was a number of undead in various places/levels that obeyed level difference green status) So its better to have all mobs without default rules, and then apply the "always aggro" flag where actually needed. |
Quote:
I'm going to post slightly more readable aggro code. I didn't test this properly but it should work. Code:
aggro.cpp Code:
ruletypes.h Code:
common.h |
I am not exactly sure what BT_Undead is? and how its different from just Undead?
|
Quote:
You can set up multiple factions to function differently. For instance, here are some factions that I use: Undead KoS (-32000) Undead KoS Assist (-32000, assist other undead in trouble) Undead (0, won't attack, yay!) Undead Assist (0, won't attack, yay! assist other undead in trouble) NonNec KoS (undead that's KoS to everyone except necromancers) That code I mentioned will only take the KoS conned mobs and make them attack higher level players if they exceed the undead threshold. Make sense? Code:
RULE_INT(Aggro, UndeadLevelAggro, 6) |
OK I see, yeah by Undead I always refer to the body type and not faction, since faction can be anything and can have any type of mobs of it ;)
Basically what I am saying that body type of a mob should be irrelevant to the rule. If mob is KOS (by faction) and has the Always Aggro FLAG - it always aggros. So it can be NON Undead and always aggro Or it can Undead and don't aggro (because of level difference) Just to be clear ;) |
It will always aggro if it is threatenly or scowl, bodytype has nothing to do with it -- the ONLY exception is if it ISN'T KoS
Did you want ALWAYS_AGGRO to apply to indifferent (ally, etc.) mobs too? |
Quote:
OK, I am sorry if I confusing you ;) So let go over this again. Normally, if we have a normal mob, that belongs to some faction and your faction is BAD (KOS or so) it will aggro. Unless you are much higher level than him. Now, the FLAG that we are discussing should allow this mob to aggro (because of my BAD faction) even if it is out of level. This FLAG should work instead of "Low INT" system that we currently have, because using INT stat for this is kind of stupid. Thats what I am trying to say =) Undead were only mentioned because it is USUALLY the type of mobs on LIVE that aggros out of level. Obviously if mob is NOT KOS, it has no reason to aggro (unless I attack it) But what will happen if mob is out of level range, my faction is good, BUT I attacked its friend? Normally mob will not assist because I am out of level, but mob with this FLAG should still assist because it sort of "fearless" Sorry again if I am giving you a headache, I just want to make sure you getting me right ;) |
Okay, let me try this again.
If it has the ALWAYS_AGGRO special ability. It will *ALWAYS* aggro if it's KoS. It doesn't matter the body type, level, intelligence, etc. It WILL aggro if this is set in my code. Now, assisting (or yelling for help) is different, and it will require an additional change. Code:
aggro.cpp Code:
common.h If a mob is set to (46) and it's KoS. It will ALWAYS ATTACK REGARDLESS OF ANYTHING. If a mob is set to (47). It will ALWAYS ASSIST ITS FACTION REGARDLESS OF ANYTHING. If it's set to both 46 and 47 it will always do both. |
Awesome ;)
Thank You so much! |
No problem
|
BUMP!
Begging the devs to implement this into official code instead of Level or INT setting. |
I just set all rats in misty to faction 1291 kos aggressive and they agro (lvl 1) on my lvl 70
|
Quote:
|
All times are GMT -4. The time now is 01:38 PM. |
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.