Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Bots

Development::Bots Forum for bots.

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #25  
Old 10-13-2015, 02:23 PM
Trackye
Sarnak
 
Join Date: Feb 2008
Posts: 87
Default

Out of curiosity...

Uleat you would probably be the best person to answer this.

A rogue backstabs.
There is code allowing the rogue to position itself behind the mob so that backstab is usable.

Lets for the purposes of this example use a clock system so if the mob is on the clock face a rogue has coding to allow it to move to 12 o'clock and attack.

could we implement a check for all other classes too? So that a rogue goes to 12 a ranger goes to 4 a tank class set to taunt and tank goes to 6 else 8 or 2. Something to that effect.

This would cause bots to partially position itself in a group setting


It seems like it would have something to do with this section
Code:
			if(AImovement_timer->Check()) {
				if(!IsMoving() && GetClass() == ROGUE && !BehindMob(GetTarget(), GetX(), GetY())) {
					// Move the rogue to behind the mob
					float newX = 0;
					float newY = 0;
					float newZ = 0;
					if(PlotPositionAroundTarget(GetTarget(), newX, newY, newZ)) {
						CalculateNewPosition2(newX, newY, newZ, GetRunspeed());
						return;
					}
				}
				else if(!IsMoving() && GetClass() != ROGUE && (DistanceSquaredNoZ(m_Position, GetTarget()->GetPosition()) < GetTarget()->GetSize())) {
					// If we are not a rogue trying to backstab, let's try to adjust our melee range so we don't appear to be bunched up
					float newX = 0;
					float newY = 0;
					float newZ = 0;
					if(PlotPositionAroundTarget(GetTarget(), newX, newY, newZ, false) && GetArchetype() != ARCHETYPE_CASTER) {
						CalculateNewPosition2(newX, newY, newZ, GetRunspeed());
						return;
					}
				}
Or
possibly there something to the effect of

Code:
					float newX = X+(rand, 1 5);
					float newY = Y+(rand, 1 5);
					float newZ = 0;

I may try to implement this in the format of many if checks for all classes

Code:
			else if(AImovement_timer->Check()) {
				if(!IsMoving() && GetClass() == RANGER && !BehindMob(GetTarget(), GetX(), GetY())) {
					// Move the ranger to below coords.
					float newX = X+3;
					float newY = Y-2;
					float newZ = 0;
					if(PlotPositionAroundTarget(GetTarget(), newX, newY, newZ)) {
						CalculateNewPosition2(newX, newY, newZ, GetRunspeed());
						return;
					}
				}
and so on but I would be happy to have another's inputs efforts go into this as well.

best place to throw an idea out and get assistance feedback!
Reply With Quote
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 10:11 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3