Mob Brain

Discussions on various DOL development features

Moderator: Support Team

Mob Brain

Postby alex_speed » Fri Apr 29, 2005 6:26 pm

Hi,

I've took a look on the StandarMobBrain, and I have some questions about the CheckNPCAggro, as I know, mob will check aggro only if it's not the same faction and mob won't check to attack an NPC, it's the NPC (guard, maybe other brain?) which will check if a mob is near it.

So I think it's more like this :

Mobs vs Mobs => ok if not same faction
Mobs vs NPC => nop
NPC (guard) vs Mobs => ok (but not for all npc)

Because in the game there is some npc that won't attack mob (realm guard which will only check to aggro a player, not a mob) and as I know, realm guard which walk around mobs, mobs won't attack guards

It's my opinion, maybe I'm wrong.
alex_speed
Inactive Staff Member
 
Posts: 691
Joined: Sun Nov 21, 2004 5:37 pm

Postby nor » Fri Apr 29, 2005 7:42 pm

Basically question is how do we make guards and realm guards. Think that would be another brain for each type of guard.
nor
Inactive Staff Member
 
Posts: 1584
Joined: Wed Mar 03, 2004 3:56 am

Postby Smallhorse » Sat Apr 30, 2005 8:26 am

Yes exactly ... either that or one guard brain with different parameters/flags that can be set via parameter string or directly (like for the single npc table on Twiki)

Actually I think we need to get away from terms like Mob and NPC ... ALL living objects beside players in game are actually NPCs ... non player characters ...

We used classes like GameMob etc because we needed different behavior, but this can be done via braintypes and brainparameters now ... so I think perhaps at one point or another we won't need a GameMob class perhaps ... because GameNPC with mob-brain would do that ...
SmallHorse
Project Ex-Administrator with too little time to be of much use currently :)
Smallhorse
Inactive Staff Member
 
Posts: 2919
Joined: Sun Jun 22, 2003 5:54 pm
ICQ: 11718314

Postby alex_speed » Sat Apr 30, 2005 9:11 am

Ok but I was pointing that with the current code I've seen, npc realm 0 will check to attack mob !=0 but I think only npc !=0 will check for npc=0

Guard and Realm guard shouldn't be to hard, maybe for realm guard, just remove the npc check and for guard inside the realm, remove the player check ? But if we do that, mob that are in the frontier will aggro realms guards.
So option are :
1) remove the npc check on standardmobbrain.
1) create new brain for frontier mob.

Edit : I think about the examine message, maybe it could be integrated with mob brain ? So we can make different examine message with brain instead of the class ? And we will have only one class, GameNPC which can have different brain
Last edited by alex_speed on Sat Apr 30, 2005 10:38 am, edited 1 time in total.
alex_speed
Inactive Staff Member
 
Posts: 691
Joined: Sun Nov 21, 2004 5:37 pm

Postby alex_speed » Sat May 14, 2005 2:46 pm

Another question, is it possible at the moment to switch the brain of a mob ?
I would like to create a GuardBrain, but if I can't change the mobbrain type.. ^^
alex_speed
Inactive Staff Member
 
Posts: 691
Joined: Sun Nov 21, 2004 5:37 pm

Postby Smallhorse » Sat May 14, 2005 4:29 pm

Yes, the brain can be changed :) ... or rather stacked ... Noret knows more about this than me :)
SmallHorse
Project Ex-Administrator with too little time to be of much use currently :)
Smallhorse
Inactive Staff Member
 
Posts: 2919
Joined: Sun Jun 22, 2003 5:54 pm
ICQ: 11718314

Postby alex_speed » Sat May 14, 2005 5:16 pm

Ok thanks, but could you (or Noret) explain how without making a new class ?
alex_speed
Inactive Staff Member
 
Posts: 691
Joined: Sun Nov 21, 2004 5:37 pm

Postby nor » Sat May 14, 2005 11:40 pm

Right now there are 2 ways;

npc.SetOwnBrain(ABrain) - sets own npc brain, has certain problems with restoring old brain if that new brain is temporary;
and
npc.AddBrain/npc.RemoveBrain - current solution for temporary brains; own brain becomes inactive while there are other brains in the list.
nor
Inactive Staff Member
 
Posts: 1584
Joined: Wed Mar 03, 2004 3:56 am

Postby FireBurst » Tue Jan 31, 2006 11:57 pm

What do I have to do if I want to set a mob to attack other players of my choice (realm or faction)? Guard mob

but I noticed that they attack players + mobs... how the hell can I set them to ONLY attack players and not mobs? cause not its TOTAL CHAOS and its ''gay''
FireBurst
DOL Enthusiast
 
Posts: 239
Joined: Sat Sep 17, 2005 1:18 am
Website: http://www.fireburst699.123.fr/
Location: Canada, Québec

Postby Batlas » Mon Mar 27, 2006 2:57 pm

I agree with SH. Creating a different brain for diff. type of mobs doesnt seem feasible.. Maybe for Dragons/Bosses but not for guards and other types of mobs that could be thought of.. setting perameters would definately be the ideal way to go about it.. Less of a resource hog imo :). Think about how many guards you would have.. And lets say for example you wanted to set animals and insects to have there own brain(For hunters to only be able to charm one or the other) and then you decide that Keep guards need there own brain as well. Now you have 1000's of mobs all pulling seperate scripts everytime they are called to do something.. I believe that would just take up memory that could be better used elsewhere. This is just speculation of course.. I might be wrong, but if I am.. Im sure one of you guys will correct me :-D
[22:29] <Arms> someones having sex upstairs -.-
[22:30] <Arms> bbl

[21:16] <Angie> do /me
[21:16] <Batlas> roflmao
[21:16] <Dalaaji> haha
[21:16] <Batlas> wow that came out bad
[21:16] <Angie> wow
[21:16] <Angie> that so came out bad
Batlas
Support Team
 
Posts: 1707
Joined: Sun Mar 21, 2004 3:11 am

Postby duff » Tue Mar 28, 2006 5:57 am

the bew db architecture is :
DBNPC

NPCID
ClassType
Name
X
Y
Z
Heading
Region
TemplateID
NPCTypeParameters
BrainClass
BrainParams

For npc and it is linked to a npc template
DBNpcTemplate

NpcTemplateID
Name
GuildName
Model
Size
MaxSpeed
EquipmentTemplateID
MeleeDamageType
ParryChance
EvadeChance
BlockChance
LeftHandSwingChance
Spells
Styles
Gender
Race
FactionID
Realm
Level
MaximumHealth
...
BrainType
BrainParams


So here you see that mob or npc can have brain param.
for this a function parseparam has been made.
I f you hwant to have param in your brain use it in code to parse param.

Npc template brain and brain param can be override in DBNPC (for npc) and in DBMobSpawner for mob.
Vive DOL vive DAOC
Image
membre de MatrixTC :mappeur,codeur :) plus d info:http://www.halflifedesign.net
User avatar
duff
Inactive Staff Member
 
Posts: 1682
Joined: Fri Jun 20, 2003 5:27 pm


Return to “%s” DOL Development Discussion

Who is online

Users browsing this forum: No registered users and 0 guests