3 void() havocbot_chooserole;
4 .float havocbot_keyboardskill;
6 vector havocbot_dodge()
8 // LordHavoc: disabled because this is too expensive
12 local vector dodge, v, n;
13 local float danger, bestdanger, vl, d;
16 // check for dangerous objects near bot or approaching bot
17 head = findchainfloat(bot_dodge, TRUE);
20 if (head.owner != self)
22 vl = vlen(head.velocity);
23 if (vl > sv_maxspeed * 0.3)
25 n = normalize(head.velocity);
26 v = self.origin - head.origin;
28 if (d > (0 - head.bot_dodgerating))
29 if (d < (vl * 0.2 + head.bot_dodgerating))
31 // calculate direction and distance from the flight path, by removing the forward axis
32 v = v - (n * (v * n));
33 danger = head.bot_dodgerating - vlen(v);
34 if (bestdanger < danger)
37 // dodge to the side of the object
44 danger = head.bot_dodgerating - vlen(head.origin - self.origin);
45 if (bestdanger < danger)
48 dodge = normalize(self.origin - head.origin);
58 .float havocbot_keyboardtime;
59 .float havocbot_ducktime;
60 .vector havocbot_keyboard;
61 void havocbot_keyboard_movement(vector destorg)
63 local vector keyboard;
64 local float blend, maxspeed;
66 maxspeed = cvar("sv_maxspeed");
68 if (time < self.havocbot_keyboardtime)
71 self.havocbot_keyboardtime =
73 self.havocbot_keyboardtime
74 + bound(0,0.05/(skill+self.havocbot_keyboardskill),0.05)
75 +random()*bound(0,0.025/(skill+self.havocbot_keyboardskill),100)
77 keyboard = self.movement * (1.0 / maxspeed);
79 local float trigger, trigger1;
80 blend = bound(0,skill*0.1,1);
81 trigger = cvar("bot_ai_keyboard_treshold");
82 trigger1 = 0 - trigger;
84 // categorize forward movement
85 // at skill < 1.5 only forward
86 // at skill < 2.5 only individual directions
87 // at skill < 4.5 only individual directions, and forward diagonals
88 // at skill >= 4.5, all cases allowed
89 if (keyboard_x > trigger)
95 else if (keyboard_x < trigger1 && skill > 1.5)
110 if (keyboard_y > trigger)
112 else if (keyboard_y < trigger1)
117 if (keyboard_z > trigger)
119 else if (keyboard_z < trigger1)
124 self.havocbot_keyboard = keyboard * maxspeed;
125 if (self.havocbot_ducktime>time) self.BUTTON_CROUCH=TRUE;
127 keyboard = self.havocbot_keyboard;
128 blend = bound(0,vlen(destorg-self.origin)/cvar("bot_ai_keyboard_distance"),1); // When getting close move with 360 degree
129 //dprint("movement ", vtos(self.movement), " keyboard ", vtos(keyboard), " blend ", ftos(blend), "\n");
130 self.movement = self.movement + (keyboard - self.movement) * blend;
133 //.float havocbotignoretime;
134 //.vector bot_dodgevector;
135 //.float bot_dodgevector_time;
136 //.float bot_dodgevector_jumpbutton;
137 void havocbot_movetogoal()
139 local vector destorg;
142 local vector flatdir;
145 local vector evadeobstacle;
146 local vector evadelava;
148 local float maxspeed;
151 //if (self.goalentity)
152 // te_lightning2(self, self.origin, (self.goalentity.absmin + self.goalentity.absmax) * 0.5);
153 self.movement = '0 0 0';
154 maxspeed = cvar("sv_maxspeed");
156 if(self.jumppadcount)
158 if(self.flags & FL_ONGROUND)
159 self.jumppadcount = FALSE;
164 if (self.goalcurrent == world)
167 navigation_poptouchedgoals();
168 if (self.goalcurrent == world)
170 if(self.alternativegoal==world)
172 // ran out of goals, rethink strategy as soon as possible
173 self.bot_strategytime = 0;
176 // try to use the alternative goal
177 navigation_findnearestwaypoint(self.alternativegoal, TRUE);
178 navigation_routetogoal(self.alternativegoal);
179 self.alternativegoal = world;
183 // te_wizspike(self.goalcurrent.origin);
184 // te_lightning2(world, self.origin, self.goalcurrent.origin);
186 m1 = self.goalcurrent.origin + self.goalcurrent.mins;
187 m2 = self.goalcurrent.origin + self.goalcurrent.maxs;
188 destorg = self.origin;
189 destorg_x = bound(m1_x, destorg_x, m2_x);
190 destorg_y = bound(m1_y, destorg_y, m2_y);
191 destorg_z = bound(m1_z, destorg_z, m2_z);
192 diff = destorg - self.origin;
194 dir = normalize(diff);
195 flatdir = diff;flatdir_z = 0;
196 flatdir = normalize(flatdir);
198 //if (self.bot_dodgevector_time < time)
200 // self.bot_dodgevector_time = time + cvar("bot_ai_dodgeupdateinterval");
201 // self.bot_dodgevector_jumpbutton = 1;
202 evadeobstacle = '0 0 0';
206 makevectors(self.v_angle);
207 self.BUTTON_JUMP = TRUE;
212 // jump if going toward an obstacle that doesn't look like stairs we
213 // can walk up directly
214 tracebox(self.origin, self.mins, self.maxs, self.origin + self.velocity * 0.2, FALSE, self);
215 if (trace_fraction < 1)
216 if (trace_plane_normal_z < 0.7)
219 tracebox(self.origin + '0 0 16', self.mins, self.maxs, self.origin + self.velocity * 0.2 + '0 0 16', FALSE, self);
220 if (trace_fraction < s + 0.01)
221 if (trace_plane_normal_z < 0.7)
224 tracebox(self.origin + '0 0 48', self.mins, self.maxs, self.origin + self.velocity * 0.2 + '0 0 48', FALSE, self);
225 if (trace_fraction > s)
226 self.BUTTON_JUMP = 1;
230 // avoiding dangers and obstacles
231 // TODO: don't make this check every frame
232 if(self.flags & FL_ONGROUND)
234 local vector dst_ahead, dst_down;
235 dst_ahead = self.origin + self.view_ofs + (self.velocity * 0.3);
236 dst_down = dst_ahead + '0 0 -1500';
238 traceline(self.origin + self.view_ofs , dst_ahead, TRUE, world);
240 if(trace_fraction == 1){
241 traceline(dst_ahead , dst_down, TRUE, world);
242 // te_lightning2(world, self.origin, dst_ahead); // Draw "ahead" look
243 s = pointcontents(trace_endpos + '0 0 1');
244 if (s != CONTENT_SOLID)
245 if (s == CONTENT_LAVA || s == CONTENT_SLIME)
246 evadelava = normalize(self.velocity) * -1;
247 else if (s == CONTENT_SKY)
248 evadeobstacle = normalize(self.velocity) * -1;
249 else if (tracebox_hits_trigger_hurt(dst_ahead, self.mins, self.maxs, trace_endpos))
251 // te_lightning2(world, dst_ahead, dst_down); // Draw "downwards" look
252 // if ain't a safe goal with "holes" (like the soylent jumpad)
253 if(!boxesoverlap(dst_ahead - self.view_ofs + self.mins, dst_ahead - self.view_ofs + self.maxs,
254 self.goalcurrent.absmin, self.goalcurrent.absmax))
256 // Remove dangerous dynamic goals from stack
257 if (self.goalcurrent.classname == "player" || self.goalcurrent.classname == "droppedweapon")
258 navigation_poproute();
261 evadeobstacle = normalize(self.velocity) * -1;
270 makevectors(self.v_angle_y * '0 1 0');
273 dodge = havocbot_dodge();
274 dodge = dodge * bound(0,3+skill*0.1,1);
275 evadelava = evadelava * bound(1,3-skill,3); //Noobs fear lava a lot and take more distance from it
276 traceline(self.origin, self.enemy.origin, TRUE, world);
277 if(trace_ent.classname == "player")
278 dir = dir * bound(0,skill/7,1);
280 dir = normalize(dir + dodge + evadeobstacle + evadelava);
281 // self.bot_dodgevector = dir;
282 // self.bot_dodgevector_jumpbutton = self.BUTTON_JUMP;
285 //dir = self.bot_dodgevector;
286 //if (self.bot_dodgevector_jumpbutton)
287 // self.BUTTON_JUMP = 1;
289 self.movement_x = dir * v_forward * maxspeed;
290 self.movement_y = dir * v_right * maxspeed;
291 self.movement_z = dir * v_up * maxspeed;
293 // Emulate keyboard interface
295 havocbot_keyboard_movement(destorg);
297 if ((dir * v_up) >= cvar("sv_jumpvelocity")*0.5 && (self.flags & FL_ONGROUND)) self.BUTTON_JUMP=1;
298 if (((dodge * v_up) > 0) && random()*frametime >= 0.2*bound(0,(10-skill)*0.1,1)) self.BUTTON_JUMP=TRUE;
299 if (((dodge * v_up) < 0) && random()*frametime >= 0.5*bound(0,(10-skill)*0.1,1)) self.havocbot_ducktime=time+0.3/bound(0.1,skill,10);
302 .float havocbot_chooseenemy_finished;
303 .float havocbot_stickenemy;
304 void havocbot_chooseenemy()
306 local entity head, best;
307 local float rating, bestrating;
309 if (cvar("bot_nofire") || IS_INDEPENDENT_PLAYER(self))
316 if (!bot_shouldattack(self.enemy))
318 // enemy died or something, find a new target
320 self.havocbot_chooseenemy_finished = time;
322 else if (self.havocbot_stickenemy)
324 // tracking last chosen enemy
325 // if enemy is visible
326 // and not really really far away
327 // and we're not severely injured
328 // then keep tracking for a half second into the future
329 traceline(self.origin+self.view_ofs, self.enemy.origin+self.enemy.view_ofs*0.5,FALSE,world);
330 if (trace_ent == self.enemy || trace_fraction == 1)
331 if (vlen(self.enemy.origin - self.origin) < 1000)
332 if (self.health > 30)
334 // remain tracking him for a shot while (case he went after a small corner or pilar
335 self.havocbot_chooseenemy_finished = time + cvar("bot_ai_enemydetectioninterval");
338 // enemy isn't visible, or is far away, or we're injured severely
339 // so stop preferring this enemy
340 // (it will still take a half second until a new one is chosen)
341 self.havocbot_stickenemy = 0;
344 if (time < self.havocbot_chooseenemy_finished)
346 self.havocbot_chooseenemy_finished = time + cvar("bot_ai_enemydetectioninterval");
347 eye = (self.origin + self.view_ofs);
349 bestrating = 100000000;
350 head = findchainfloat(bot_attack, TRUE);
353 v = (head.absmin + head.absmax) * 0.5;
354 rating = vlen(v - eye);
355 if (bestrating > rating)
356 if (bot_shouldattack(head))
358 traceline(eye, v, TRUE, self);
359 if (trace_ent == head || trace_fraction >= 1)
368 self.havocbot_stickenemy = TRUE;
371 .float bot_chooseweapontime;
372 float(entity e) w_getbestweapon;
373 void havocbot_chooseweapon()
375 // TODO: clean this up by moving it to weapon code
376 if(self.enemy.classname!="player")
378 self.switchweapon = w_getbestweapon(self);
383 local float rocket ; rocket =-1000;
384 local float nex ; nex =-1000;
385 local float hagar ; hagar =-1000;
386 local float grenade ; grenade =-1000;
387 local float electro ; electro =-1000;
388 local float crylink ; crylink =-1000;
389 local float uzi ; uzi =-1000;
390 local float shotgun ; shotgun =-1000;
391 local float campingrifle ; campingrifle =-1000;
392 local float laser ; laser =-1000;
393 local float minstanex ; minstanex =-1000;
394 local float currentscore;
395 local float bestscore; bestscore = 0;
396 local float bestweapon; bestweapon=self.switchweapon;
397 local float distance; distance=bound(10,vlen(self.origin-self.enemy.origin)-200,10000);
398 local float maxdelaytime=0.5;
399 local float spreadpenalty=10;
400 local float distancefromfloor;
402 local float af, ct, combo_time;
404 traceline(self.enemy.origin,self.enemy.origin-'0 0 1000',TRUE,world);
405 distancefromfloor = self.enemy.origin_z - trace_endpos_z;
407 af = ATTACK_FINISHED(self);
408 ct = cvar("bot_ai_weapon_combo_threshold");
410 // Bots with no skill will be 4 times more slower than "godlike" bots when doing weapon combos
411 // Ideally this 4 should be calculated as longest_weapon_refire / bot_ai_weapon_combo_threshold
412 combo_time = time + ct + (ct * ((-0.3*skill)+3));
414 // Custom weapon list based on distance to the enemy
415 local float i; i = 0;
416 if(bot_custom_weapon){
418 // Choose weapons for far distance
419 if ( distance > bot_distance_far ) {
420 for(i=0; i < WEP_LAST && bot_weapons_far[i] != -1 ; ++i){
421 w = bot_weapons_far[i];
422 if ( client_hasweapon(self, w, TRUE, FALSE) ){
423 if ( self.weapon == w){
424 if( cvar("bot_ai_weapon_combo") && af > combo_time)
427 self.switchweapon = w;
434 // Choose weapons for mid distance
435 if ( distance > bot_distance_close ) {
436 for(i=0; i < WEP_LAST && bot_weapons_mid[i] != -1 ; ++i){
437 w = bot_weapons_mid[i];
438 if ( client_hasweapon(self, w, TRUE, FALSE) ){
439 if ( self.weapon == w){
440 if( cvar("bot_ai_weapon_combo") && af > combo_time)
443 self.switchweapon = w;
450 // Choose weapons for close distance
451 for(i=0; i < WEP_LAST && bot_weapons_close[i] != -1 ; ++i){
452 w = bot_weapons_close[i];
453 if ( client_hasweapon(self, w, TRUE, FALSE) ){
454 if ( self.weapon == w){
455 if( cvar("bot_ai_weapon_combo") && af > combo_time)
458 self.switchweapon = w;
463 // If now weapon was chosen by this system fall back to the previous one
467 // (Damage/Sec * Weapon spefic change to get that damage)
468 // *(Time to get to target * weapon specfic hitchange bonus) / (in a time of maxdelaytime)
469 // *(Spread change of hit) // if it applies
470 // *(Penality for target beeing in air)
472 if (client_hasweapon(self, WEP_MINSTANEX, TRUE, FALSE))
473 minstanex = (1000/cvar("g_balance_minstanex_refire")*1.0)
476 if (client_hasweapon(self, WEP_ROCKET_LAUNCHER, TRUE, FALSE) &&
477 !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_ROCKET_LAUNCHER &&
481 rocket = (cvar("g_balance_rocketlauncher_damage")/cvar("g_balance_rocketlauncher_refire")*0.75)
482 * bound(0,(cvar("g_balance_rocketlauncher_speed")/distance*maxdelaytime),1)*1.5;
484 if (client_hasweapon(self, WEP_NEX, TRUE, FALSE) &&
485 !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_NEX &&
489 nex = (cvar("g_balance_nex_damage")/cvar("g_balance_nex_refire")*1.0)
492 if (client_hasweapon(self, WEP_HAGAR, TRUE, FALSE) ) // &&
493 // !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_HAGAR && time < self.bot_lastshot + cvar("g_balance_hagar_primary_refire") ))
494 hagar = (cvar("g_balance_hagar_primary_damage")/cvar("g_balance_hagar_primary_refire")*1.0)
495 * bound(0,(cvar("g_balance_hagar_primary_speed")/distance*maxdelaytime),1)*0.2;
497 if (client_hasweapon(self, WEP_GRENADE_LAUNCHER, TRUE, FALSE) &&
499 cvar("bot_ai_weapon_combo") && self.weapon == WEP_GRENADE_LAUNCHER &&
503 grenade = (cvar("g_balance_grenadelauncher_primary_damage")/cvar("g_balance_grenadelauncher_primary_refire")*1.0)
504 * bound(0,(cvar("g_balance_grenadelauncher_primary_speed")/distance*maxdelaytime),1)*1.1;
506 if (client_hasweapon(self, WEP_ELECTRO, TRUE, FALSE) &&
507 !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_ELECTRO &&
511 electro = (cvar("g_balance_electro_primary_damage")/cvar("g_balance_electro_primary_refire")*0.75)
512 * bound(0,(cvar("g_balance_electro_primary_speed")/distance*maxdelaytime),1)*1.0;
514 if (client_hasweapon(self, WEP_CRYLINK, TRUE, FALSE) ) // &&
515 // !( self.weapon == WEP_CRYLINK && time < self.bot_lastshot + cvar("g_balance_crylink_primary_refire") ))
516 crylink = (cvar("g_balance_crylink_primary_damage")/cvar("g_balance_crylink_primary_refire")*1.0)
517 * bound(0,(cvar("g_balance_crylink_primary_speed")/distance*maxdelaytime),1)*(64/(32+cvar("g_balance_crylink_primary_spread")*distance))*1.0;
519 if (client_hasweapon(self, WEP_UZI, TRUE, FALSE) ) // &&
520 // !( self.weapon == WEP_UZI && time < self.bot_lastshot + cvar("g_balance_uzi_sustained_refire") ))
521 uzi = (cvar("g_balance_uzi_sustained_damage")/cvar("g_balance_uzi_sustained_refire")*1.0)
522 * bound(0,32/(32+cvar("g_balance_uzi_sustained_spread")*distance),1);
524 if (client_hasweapon(self, WEP_SHOTGUN, TRUE, FALSE) &&
525 !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_SHOTGUN &&
529 shotgun = (cvar("g_balance_shotgun_primary_damage")*cvar("g_balance_shotgun_primary_bullets")/cvar("g_balance_shotgun_primary_refire")*1.0)
530 * bound(0,32/(32+cvar("g_balance_shotgun_primary_spread")*distance),1);
532 if (client_hasweapon(self, WEP_LASER, FALSE, FALSE) &&
533 !( cvar("bot_ai_weapon_combo") && self.weapon == WEP_LASER &&
537 laser = (cvar("g_balance_laser_primary_damage")/cvar("g_balance_laser_primary_refire")*1.0)
538 * bound(0,cvar("g_balance_laser_primary_speed")/distance*maxdelaytime,1);
540 if((self.enemy.flags & FL_ONGROUND)==FALSE){
541 rocket = rocket * (1.5-bound(0, distancefromfloor/cvar("g_balance_rocketlauncher_radius" ),0.9)); //slight bigger change
542 grenade = grenade * (1.5-bound(0,distancefromfloor/cvar("g_balance_grenadelauncher_primary_radius"),0.95));
543 electro = electro * (1.5-bound(0,distancefromfloor/cvar("g_balance_electro_primary_radius" ),0.95));
544 laser = laser * (1.5-bound(0,distancefromfloor/cvar("g_balance_laser_primary_radius" ),0.95));
547 dprint("Floor distance: ",ftos(distancefromfloor),"\n");
548 dprint("Rocket: " , ftos(rocket ), "\n");
549 dprint("Nex: " , ftos(nex ), "\n");
550 dprint("Hagar: " , ftos(hagar ), "\n");
551 dprint("Grenade: ", ftos(grenade ), "\n");
552 dprint("Electro: ", ftos(electro ), "\n");
553 dprint("Crylink: ", ftos(crylink ), "\n");
554 dprint("Uzi: " , ftos(uzi ), "\n");
555 dprint("Shotgun :", ftos(shotgun ), "\n");
556 dprint("Laser :", ftos(laser ), "\n\n");
559 w = WEP_MINSTANEX ;s = minstanex;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
560 w = WEP_ROCKET_LAUNCHER ;s = rocket ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
561 w = WEP_NEX ;s = nex ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
562 w = WEP_HAGAR ;s = hagar ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
563 w = WEP_GRENADE_LAUNCHER ;s = grenade ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
564 w = WEP_ELECTRO ;s = electro ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
565 w = WEP_CRYLINK ;s = crylink ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
566 w = WEP_UZI ;s = uzi ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
567 w = WEP_SHOTGUN ;s = shotgun ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
568 w = WEP_LASER ;s = laser ;if (s > bestscore){bestscore = s;bestweapon = w;} if (self.switchweapon == w) currentscore = s;
570 // switch if the best weapon would provide a significant damage increase
571 if (bestscore > currentscore*1.5){
572 self.switchweapon = bestweapon;
574 // buys time for detonating the rocket. not tested yet
575 if ( cvar("bot_ai_weapon_combo") && bestweapon == WEP_ROCKET_LAUNCHER )
576 self.bot_chooseweapontime += (distance / cvar("g_balance_rocketlauncher_speed"));
583 local vector selfvel, enemyvel;
584 if(self.flags & FL_INWATER)
586 if (time < self.nextaim)
588 self.nextaim = time + 0.1;
589 selfvel = self.velocity;
590 if (!self.waterlevel)
594 enemyvel = self.enemy.velocity;
595 if (!self.enemy.waterlevel)
597 lag_additem(time + self.ping, 0, 0, self.enemy, self.origin, selfvel, self.enemy.origin, enemyvel);
600 lag_additem(time + self.ping, 0, 0, world, self.origin, selfvel, self.goalcurrent.origin, '0 0 0');
605 if (bot_strategytoken == self)
606 if (!bot_strategytoken_taken)
608 self.havocbot_role();
609 // token has been used this frame
610 bot_strategytoken_taken = TRUE;
615 havocbot_chooseenemy();
616 if (self.bot_chooseweapontime < time )
618 self.bot_chooseweapontime = time + cvar("bot_ai_chooseweaponinterval");
619 havocbot_chooseweapon();
623 if (self.bot_aimtarg)
625 weapon_action(self.weapon, WR_AIM);
626 if (cvar("bot_nofire") || IS_INDEPENDENT_PLAYER(self))
628 self.BUTTON_ATCK = FALSE;
629 self.BUTTON_ATCK2 = FALSE;
632 else if (self.goalcurrent)
634 local vector now,v,next;//,heading;
635 local float distance,skillblend,distanceblend,blend;
636 next = now = self.goalcurrent.origin - (self.origin + self.view_ofs);
637 distance = vlen(now);
638 //heading = self.velocity;
639 //dprint(self.goalstack01.classname,etos(self.goalstack01),"\n");
640 if(self.goalstack01 != self && self.goalstack01 != world)
641 next = self.goalstack01.origin - (self.origin + self.view_ofs);
642 skillblend=bound(0,(skill-2.5)*0.5,1); //lower skill player can't preturn
643 distanceblend=bound(0,distance/cvar("bot_ai_keyboard_distance"),1);
644 blend = skillblend * (1-distanceblend);
645 //v = (now * (distanceblend) + next * (1-distanceblend)) * (skillblend) + now * (1-skillblend);
646 //v = now * (distanceblend) * (skillblend) + next * (1-distanceblend) * (skillblend) + now * (1-skillblend);
647 //v = now * ((1-skillblend) + (distanceblend) * (skillblend)) + next * (1-distanceblend) * (skillblend);
648 v = now + blend * (next - now);
649 //dprint(etos(self), " ");
650 //dprint(vtos(now), ":", vtos(next), "=", vtos(v), " (blend ", ftos(blend), ")\n");
651 //v = now * (distanceblend) + next * (1-distanceblend);
652 if (self.waterlevel < 2)
654 //dprint("walk at:", vtos(v), "\n");
655 //te_lightning2(world, self.origin, self.goalcurrent.origin);
658 havocbot_movetogoal();
661 void havocbot_setupbot()
663 self.bot_ai = havocbot_ai;
664 // will be updated by think code
665 //Generate some random skill levels
666 self.havocbot_keyboardskill=random()-0.5;
667 havocbot_chooserole();