ManaPlus
Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes
CrazyMoves Class Reference

#include <crazymoves.h>

Public Member Functions

 CrazyMoves ()
 
void crazyMove ()
 

Protected Member Functions

void crazyMoveA ()
 
void crazyMoveAd () const
 
void crazyMoveAe () const
 
void crazyMoveAm () const
 
void crazyMoveAo () const
 

Static Protected Member Functions

static void crazyMove1 ()
 
static void crazyMove2 ()
 
static void crazyMove3 ()
 
static void crazyMove4 ()
 
static void crazyMove5 ()
 
static void crazyMove6 ()
 
static void crazyMove7 ()
 
static void crazyMove8 ()
 
static void crazyMove9 ()
 
static void crazyMoveAs ()
 

Protected Attributes

std::string mMoveProgram
 
bool mDisableCrazyMove
 

Detailed Description

Definition at line 31 of file crazymoves.h.

Constructor & Destructor Documentation

◆ CrazyMoves()

CrazyMoves::CrazyMoves ( )

Definition at line 49 of file crazymoves.cpp.

49  :
50  mMoveProgram(),
51  mDisableCrazyMove(false)
52 {
53 }
std::string mMoveProgram
Definition: crazymoves.h:55
bool mDisableCrazyMove
Definition: crazymoves.h:58

Member Function Documentation

◆ crazyMove()

void CrazyMoves::crazyMove ( )

Definition at line 55 of file crazymoves.cpp.

56 {
57  const bool oldDisableCrazyMove = mDisableCrazyMove;
58  mDisableCrazyMove = true;
59  switch (settings.crazyMoveType)
60  {
61  case 1:
62  crazyMove1();
63  break;
64  case 2:
65  crazyMove2();
66  break;
67  case 3:
68  crazyMove3();
69  break;
70  case 4:
71  crazyMove4();
72  break;
73  case 5:
74  crazyMove5();
75  break;
76  case 6:
77  crazyMove6();
78  break;
79  case 7:
80  crazyMove7();
81  break;
82  case 8:
83  crazyMove8();
84  break;
85  case 9:
86  crazyMove9();
87  break;
88  case 10:
89  crazyMoveA();
90  break;
91  default:
92  break;
93  }
94  mDisableCrazyMove = oldDisableCrazyMove;
95 }
static void crazyMove9()
Definition: crazymoves.cpp:458
static void crazyMove7()
Definition: crazymoves.cpp:318
void crazyMoveA()
Definition: crazymoves.cpp:768
static void crazyMove1()
Definition: crazymoves.cpp:97
static void crazyMove5()
Definition: crazymoves.cpp:248
static void crazyMove6()
Definition: crazymoves.cpp:271
static void crazyMove8()
Definition: crazymoves.cpp:349
static void crazyMove4()
Definition: crazymoves.cpp:225
static void crazyMove3()
Definition: crazymoves.cpp:187
static void crazyMove2()
Definition: crazymoves.cpp:136
unsigned int crazyMoveType
Definition: settings.h:134
Settings settings
Definition: settings.cpp:32

References crazyMove1(), crazyMove2(), crazyMove3(), crazyMove4(), crazyMove5(), crazyMove6(), crazyMove7(), crazyMove8(), crazyMove9(), crazyMoveA(), Settings::crazyMoveType, mDisableCrazyMove, and settings.

Referenced by LocalPlayer::specialMove().

◆ crazyMove1()

void CrazyMoves::crazyMove1 ( )
staticprotected

Definition at line 97 of file crazymoves.cpp.

98 {
99  if ((localPlayer == nullptr) ||
100  (playerHandler == nullptr) ||
102  {
103  return;
104  }
105 
106 // if (!PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
107 // return;
108 
109  switch (localPlayer->getDirection())
110  {
111  case BeingDirection::UP:
115  break;
120  break;
125  break;
130  break;
131  default:
132  break;
133  }
134 }
virtual void setDirection(const uint8_t direction)
Definition: being.cpp:1690
uint8_t getDirection() const
Definition: being.h:494
BeingActionT getCurrentAction() const
Definition: being.h:482
void setWalkingDir(const unsigned char dir)
virtual void setDirection(const unsigned char direction) const =0
LocalPlayer * localPlayer
Net::PlayerHandler * playerHandler
Definition: net.cpp:96

References BeingDirection::DOWN, Being::getCurrentAction(), Being::getDirection(), BeingDirection::LEFT, localPlayer, BeingAction::MOVE, playerHandler, BeingDirection::RIGHT, Being::setDirection(), Net::PlayerHandler::setDirection(), LocalPlayer::setWalkingDir(), and BeingDirection::UP.

Referenced by crazyMove().

◆ crazyMove2()

void CrazyMoves::crazyMove2 ( )
staticprotected

Definition at line 136 of file crazymoves.cpp.

137 {
138  if ((localPlayer == nullptr) ||
139  (playerHandler == nullptr) ||
141  {
142  return;
143  }
144 
145 // if (!PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
146 // return;
147 
148  switch (localPlayer->getDirection())
149  {
150  case BeingDirection::UP:
156  break;
157 
164  break;
165 
172  break;
173 
180  break;
181 
182  default:
183  break;
184  }
185 }

References BeingDirection::DOWN, Being::getCurrentAction(), Being::getDirection(), BeingDirection::LEFT, localPlayer, BeingAction::MOVE, playerHandler, BeingDirection::RIGHT, Being::setDirection(), Net::PlayerHandler::setDirection(), LocalPlayer::setWalkingDir(), and BeingDirection::UP.

Referenced by crazyMove().

◆ crazyMove3()

void CrazyMoves::crazyMove3 ( )
staticprotected

Definition at line 187 of file crazymoves.cpp.

188 {
189  if ((localPlayer == nullptr) ||
190  (playerHandler == nullptr) ||
192  {
193  return;
194  }
195 
196  switch (settings.crazyMoveState)
197  {
198  case 0:
199  localPlayer->move(1, 1);
201  break;
202  case 1:
203  localPlayer->move(1, -1);
205  break;
206  case 2:
207  localPlayer->move(-1, -1);
209  break;
210  case 3:
211  localPlayer->move(-1, 1);
213  break;
214  default:
215  break;
216  }
217 
218 // if (!PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
219 // return;
220 
223 }
void move(const int dX, const int dY)
unsigned int crazyMoveState
Definition: settings.h:145

References Settings::crazyMoveState, BeingDirection::DOWN, Being::getCurrentAction(), localPlayer, LocalPlayer::move(), BeingAction::MOVE, playerHandler, Being::setDirection(), Net::PlayerHandler::setDirection(), and settings.

Referenced by crazyMove().

◆ crazyMove4()

void CrazyMoves::crazyMove4 ( )
staticprotected

Definition at line 225 of file crazymoves.cpp.

226 {
227  if ((localPlayer == nullptr) ||
229  {
230  return;
231  }
232 
233  switch (settings.crazyMoveState)
234  {
235  case 0:
236  localPlayer->move(7, 0);
238  break;
239  case 1:
240  localPlayer->move(-7, 0);
242  break;
243  default:
244  break;
245  }
246 }

References Settings::crazyMoveState, Being::getCurrentAction(), localPlayer, LocalPlayer::move(), BeingAction::MOVE, and settings.

Referenced by crazyMove().

◆ crazyMove5()

void CrazyMoves::crazyMove5 ( )
staticprotected

Definition at line 248 of file crazymoves.cpp.

249 {
250  if ((localPlayer == nullptr) ||
252  {
253  return;
254  }
255 
256  switch (settings.crazyMoveState)
257  {
258  case 0:
259  localPlayer->move(0, 7);
261  break;
262  case 1:
263  localPlayer->move(0, -7);
265  break;
266  default:
267  break;
268  }
269 }

References Settings::crazyMoveState, Being::getCurrentAction(), localPlayer, LocalPlayer::move(), BeingAction::MOVE, and settings.

Referenced by crazyMove().

◆ crazyMove6()

void CrazyMoves::crazyMove6 ( )
staticprotected

Definition at line 271 of file crazymoves.cpp.

272 {
273  if ((localPlayer == nullptr) ||
275  {
276  return;
277  }
278 
279  switch (settings.crazyMoveState)
280  {
281  case 0:
282  localPlayer->move(3, 0);
284  break;
285  case 1:
286  localPlayer->move(2, -2);
288  break;
289  case 2:
290  localPlayer->move(0, -3);
292  break;
293  case 3:
294  localPlayer->move(-2, -2);
296  break;
297  case 4:
298  localPlayer->move(-3, 0);
300  break;
301  case 5:
302  localPlayer->move(-2, 2);
304  break;
305  case 6:
306  localPlayer->move(0, 3);
308  break;
309  case 7:
310  localPlayer->move(2, 2);
312  break;
313  default:
314  break;
315  }
316 }

References Settings::crazyMoveState, Being::getCurrentAction(), localPlayer, LocalPlayer::move(), BeingAction::MOVE, and settings.

Referenced by crazyMove().

◆ crazyMove7()

void CrazyMoves::crazyMove7 ( )
staticprotected

Definition at line 318 of file crazymoves.cpp.

319 {
320  if ((localPlayer == nullptr) ||
322  {
323  return;
324  }
325 
326  switch (settings.crazyMoveState)
327  {
328  case 0:
329  localPlayer->move(1, 1);
331  break;
332  case 1:
333  localPlayer->move(-1, 1);
335  break;
336  case 2:
337  localPlayer->move(-1, -1);
339  break;
340  case 3:
341  localPlayer->move(1, -1);
343  break;
344  default:
345  break;
346  }
347 }

References Settings::crazyMoveState, Being::getCurrentAction(), localPlayer, LocalPlayer::move(), BeingAction::MOVE, and settings.

Referenced by crazyMove().

◆ crazyMove8()

void CrazyMoves::crazyMove8 ( )
staticprotected

Definition at line 349 of file crazymoves.cpp.

350 {
351  if (localPlayer == nullptr ||
353  {
354  return;
355  }
356  const Map *const map = localPlayer->getMap();
357  if (map == nullptr)
358  return;
359  const int x = localPlayer->getTileX();
360  const int y = localPlayer->getTileY();
361  int idx = 0;
362  const int dist = 1;
363 
364 // look
365 // up, ri,do,le
366  static const int movesX[][4] =
367  {
368  {-1, 0, 1, 0}, // move left
369  { 0, 1, 0, -1}, // move up
370  { 1, 0, -1, 0}, // move right
371  { 0, -1, 0, 1} // move down
372  };
373 
374 // look
375 // up, ri,do,le
376  static const int movesY[][4] =
377  {
378  { 0, -1, 0, 1}, // move left
379  {-1, 0, 1, 0}, // move up
380  { 0, 1, 0, -1}, // move right
381  { 1, 0, -1, 0} // move down
382  };
383 
384  switch (localPlayer->getDirection())
385  {
386  case BeingDirection::UP:
387  idx = 0;
388  break;
389 
391  idx = 1;
392  break;
393 
395  idx = 2;
396  break;
397 
399  idx = 3;
400  break;
401 
402  default:
403  break;
404  }
405 
406  int mult = 1;
407  const unsigned char blockWalkMask = localPlayer->getBlockWalkMask();
408  if (map->getWalk(x + movesX[idx][0],
409  y + movesY[idx][0], blockWalkMask))
410  {
411  while (map->getWalk(x + movesX[idx][0] * mult,
412  y + movesY[idx][0] * mult,
413  blockWalkMask) && mult <= dist)
414  {
415  mult ++;
416  }
417  localPlayer->move(movesX[idx][0] * (mult - 1),
418  movesY[idx][0] * (mult - 1));
419  }
420  else if (map->getWalk(x + movesX[idx][1],
421  y + movesY[idx][1], blockWalkMask))
422  {
423  while (map->getWalk(x + movesX[idx][1] * mult,
424  y + movesY[idx][1] * mult,
425  blockWalkMask) && mult <= dist)
426  {
427  mult ++;
428  }
429  localPlayer->move(movesX[idx][1] * (mult - 1),
430  movesY[idx][1] * (mult - 1));
431  }
432  else if (map->getWalk(x + movesX[idx][2],
433  y + movesY[idx][2], blockWalkMask))
434  {
435  while (map->getWalk(x + movesX[idx][2] * mult,
436  y + movesY[idx][2] * mult,
437  blockWalkMask) && mult <= dist)
438  {
439  mult ++;
440  }
441  localPlayer->move(movesX[idx][2] * (mult - 1),
442  movesY[idx][2] * (mult - 1));
443  }
444  else if (map->getWalk(x + movesX[idx][3],
445  y + movesY[idx][3], blockWalkMask))
446  {
447  while (map->getWalk(x + movesX[idx][3] * mult,
448  y + movesY[idx][3] * mult,
449  blockWalkMask) && mult <= dist)
450  {
451  mult ++;
452  }
453  localPlayer->move(movesX[idx][3] * (mult - 1),
454  movesY[idx][3] * (mult - 1));
455  }
456 }
const Map * getMap() const
Definition: actor.h:130
int getTileX() const
Definition: being.h:168
int getTileY() const
Definition: being.h:174
unsigned char getBlockWalkMask() const A_CONST
Definition: map.h:75
bool getWalk(const int x, const int y, const unsigned char blockWalkMask) const
Definition: map.cpp:785
static const int blockWalkMask

References blockWalkMask, BeingDirection::DOWN, LocalPlayer::getBlockWalkMask(), Being::getCurrentAction(), Being::getDirection(), Actor::getMap(), Being::getTileX(), Being::getTileY(), Map::getWalk(), BeingDirection::LEFT, localPlayer, LocalPlayer::move(), BeingAction::MOVE, BeingDirection::RIGHT, BeingDirection::UP, x, and y.

Referenced by crazyMove().

◆ crazyMove9()

void CrazyMoves::crazyMove9 ( )
staticprotected

Definition at line 458 of file crazymoves.cpp.

459 {
460  int dx = 0;
461  int dy = 0;
462 
463  if (localPlayer == nullptr ||
465  {
466  return;
467  }
468 
469  switch (settings.crazyMoveState)
470  {
471  case 0:
472  switch (localPlayer->getDirection())
473  {
474  case BeingDirection::UP : dy = -1; break;
475  case BeingDirection::DOWN : dy = 1; break;
476  case BeingDirection::LEFT : dx = -1; break;
477  case BeingDirection::RIGHT: dx = 1; break;
478  default: break;
479  }
480  localPlayer->move(dx, dy);
482  break;
483  case 1:
485  if (!localPlayer->allowAction())
486  return;
487  if (playerHandler != nullptr)
489  break;
490  case 2:
492  break;
493  case 3:
495  break;
496  default:
497  break;
498  }
499 }
bool allowAction()
virtual void changeAction(const BeingActionT &action) const =0

References LocalPlayer::allowAction(), Net::PlayerHandler::changeAction(), Settings::crazyMoveState, BeingDirection::DOWN, Being::getCurrentAction(), Being::getDirection(), BeingDirection::LEFT, localPlayer, LocalPlayer::move(), BeingAction::MOVE, playerHandler, BeingDirection::RIGHT, settings, BeingAction::SIT, and BeingDirection::UP.

Referenced by crazyMove().

◆ crazyMoveA()

void CrazyMoves::crazyMoveA ( )
protected

Definition at line 768 of file crazymoves.cpp.

769 {
770  mMoveProgram = config.getStringValue("crazyMoveProgram");
771 
773  return;
774 
775  if (mMoveProgram.empty())
776  return;
777 
778  if (settings.crazyMoveState >= mMoveProgram.length())
780 
781  // move command
783  {
784  crazyMoveAm();
785  }
786  // direction command
787  else if (mMoveProgram[settings.crazyMoveState] == 'd')
788  {
789  crazyMoveAd();
790  }
791  // sit command
792  else if (mMoveProgram[settings.crazyMoveState] == 's')
793  {
794  crazyMoveAs();
795  }
796  // wear outfits
797  else if (mMoveProgram[settings.crazyMoveState] == 'o')
798  {
799  crazyMoveAo();
800  }
801  // pause
802  else if (mMoveProgram[settings.crazyMoveState] == 'w')
803  {
805  }
806  // pick up
807  else if (mMoveProgram[settings.crazyMoveState] == 'p')
808  {
811  }
812  // emote
813  else if (mMoveProgram[settings.crazyMoveState] == 'e'
815  {
816  crazyMoveAe();
817  }
818  else
819  {
821  }
822 
823  if (settings.crazyMoveState >= mMoveProgram.length())
825 }
std::string getStringValue(const std::string &key) const
void crazyMoveAd() const
Definition: crazymoves.cpp:579
void crazyMoveAe() const
Definition: crazymoves.cpp:740
void crazyMoveAm() const
Definition: crazymoves.cpp:501
void crazyMoveAo() const
Definition: crazymoves.cpp:720
static void crazyMoveAs()
Definition: crazymoves.cpp:713
bool pickUpItems(int pickUpType)
Configuration config

References config, crazyMoveAd(), crazyMoveAe(), crazyMoveAm(), crazyMoveAo(), crazyMoveAs(), Settings::crazyMoveState, Being::getCurrentAction(), Configuration::getStringValue(), localPlayer, mMoveProgram, BeingAction::MOVE, LocalPlayer::pickUpItems(), and settings.

Referenced by crazyMove().

◆ crazyMoveAd()

void CrazyMoves::crazyMoveAd ( ) const
protected

Definition at line 579 of file crazymoves.cpp.

580 {
582 
583  if (settings.crazyMoveState < mMoveProgram.length())
584  {
585  signed char param = mMoveProgram[settings.crazyMoveState++];
586  if (param == '?')
587  {
588  const char cmd[] = {'l', 'r', 'u', 'd'};
589  srand(tick_time);
590  param = cmd[rand() % 4];
591  }
592  switch (param)
593  {
594  case 'd':
595 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
596  {
600  }
601  break;
602  case 'u':
603 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
604  {
608  }
609  break;
610  case 'l':
611 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
612  {
616  }
617  break;
618  case 'r':
619 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
620  {
624  }
625  break;
626  case 'L':
627 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
628  {
629  uint8_t dir = 0;
630  switch (localPlayer->getDirection())
631  {
632  case BeingDirection::UP:
633  dir = BeingDirection::LEFT;
634  break;
636  dir = BeingDirection::RIGHT;
637  break;
639  dir = BeingDirection::DOWN;
640  break;
642  dir = BeingDirection::UP;
643  break;
644  default:
645  break;
646  }
649  }
650  break;
651  case 'R':
652 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
653  {
654  uint8_t dir = 0;
655  switch (localPlayer->getDirection())
656  {
657  case BeingDirection::UP:
658  dir = BeingDirection::RIGHT;
659  break;
661  dir = BeingDirection::LEFT;
662  break;
664  dir = BeingDirection::UP;
665  break;
667  dir = BeingDirection::DOWN;
668  break;
669  default:
670  break;
671  }
674  }
675  break;
676  case 'b':
677 // if (PacketLimiter::limitPackets(PacketType::PACKET_DIRECTION))
678  {
679  uint8_t dir = 0;
680  switch (localPlayer->getDirection())
681  {
682  case BeingDirection::UP:
683  dir = BeingDirection::DOWN;
684  break;
686  dir = BeingDirection::UP;
687  break;
689  dir = BeingDirection::RIGHT;
690  break;
692  dir = BeingDirection::LEFT;
693  break;
694  default:
695  break;
696  }
699  }
700  break;
701  case '0':
703  break;
704  case 'a':
706  break;
707  default:
708  break;
709  }
710  }
711 }
void dropFirst() const
void dropItems(const int cnt)
DropShortcut * dropShortcut
volatile int tick_time
Definition: timer.cpp:53

References Settings::crazyMoveState, BeingDirection::DOWN, DropShortcut::dropFirst(), DropShortcut::dropItems(), dropShortcut, Being::getDirection(), BeingDirection::LEFT, localPlayer, mMoveProgram, playerHandler, BeingDirection::RIGHT, Being::setDirection(), Net::PlayerHandler::setDirection(), settings, tick_time, and BeingDirection::UP.

Referenced by crazyMoveA().

◆ crazyMoveAe()

void CrazyMoves::crazyMoveAe ( ) const
protected

Definition at line 740 of file crazymoves.cpp.

741 {
743  const signed char emo = mMoveProgram[settings.crazyMoveState];
744  unsigned char emoteId = 0;
745  if (emo == '?')
746  {
747  srand(tick_time);
748  emoteId = CAST_U8(
749  1 + (rand() % EmoteDB::size()));
750  }
751  else
752  {
753  if (emo >= '0' && emo <= '9')
754  emoteId = CAST_U8(emo - '0' + 1);
755  else if (emo >= 'a' && emo <= 'z')
756  emoteId = CAST_U8(emo - 'a' + 11);
757  else if (emo >= 'A' && emo <= 'Z')
758  emoteId = CAST_U8(emo - 'A' + 37);
759  }
760  if (mMoveProgram[settings.crazyMoveState - 1] == 'e')
761  LocalPlayer::emote(emoteId);
763  petHandler->emote(emoteId);
764 
766 }
#define CAST_U8
Definition: cast.h:27
static bool emote(const uint8_t emotion)
virtual void emote(const uint8_t emoteId)=0
int size()
Definition: emotedb.cpp:306
bool limitPackets(const PacketTypeT type)
Net::PetHandler * petHandler
Definition: net.cpp:95

References CAST_U8, Settings::crazyMoveState, Net::PetHandler::emote(), LocalPlayer::emote(), PacketLimiter::limitPackets(), mMoveProgram, PacketType::PACKET_CHAT, petHandler, settings, EmoteDB::size(), and tick_time.

Referenced by crazyMoveA().

◆ crazyMoveAm()

void CrazyMoves::crazyMoveAm ( ) const
protected

Definition at line 501 of file crazymoves.cpp.

502 {
503  if (localPlayer == nullptr)
504  return;
505 
507  if (settings.crazyMoveState < mMoveProgram.length())
508  {
509  int dx = 0;
510  int dy = 0;
511 
512  signed char param = mMoveProgram[settings.crazyMoveState++];
513  if (param == '?')
514  {
515  const char cmd[] = {'l', 'r', 'u', 'd', 'L', 'R', 'U', 'D'};
516  srand(tick_time);
517  param = cmd[rand() % 8];
518  }
519  switch (param)
520  {
521  case 'd':
522  localPlayer->move(0, 1);
523  break;
524  case 'u':
525  localPlayer->move(0, -1);
526  break;
527  case 'l':
528  localPlayer->move(-1, 0);
529  break;
530  case 'r':
531  localPlayer->move(1, 0);
532  break;
533  case 'D':
534  localPlayer->move(1, 1);
535  break;
536  case 'U':
537  localPlayer->move(-1, -1);
538  break;
539  case 'L':
540  localPlayer->move(-1, 1);
541  break;
542  case 'R':
543  localPlayer->move(1, -1);
544  break;
545  case 'f':
546  {
547  const uint8_t dir = localPlayer->getDirection();
548  if ((dir & BeingDirection::UP) != 0)
549  dy = -1;
550  else if ((dir & BeingDirection::DOWN) != 0)
551  dy = 1;
552  if ((dir & BeingDirection::LEFT) != 0)
553  dx = -1;
554  else if ((dir & BeingDirection::RIGHT) != 0)
555  dx = 1;
556  localPlayer->move(dx, dy);
557  break;
558  }
559  case 'b':
560  {
561  const uint8_t dir = localPlayer->getDirection();
562  if ((dir & BeingDirection::UP) != 0)
563  dy = 1;
564  else if ((dir & BeingDirection::DOWN) != 0)
565  dy = -1;
566  if ((dir & BeingDirection::LEFT) != 0)
567  dx = 1;
568  else if ((dir & BeingDirection::RIGHT) != 0)
569  dx = -1;
570  localPlayer->move(dx, dy);
571  break;
572  }
573  default:
574  break;
575  }
576  }
577 }

References Settings::crazyMoveState, BeingDirection::DOWN, Being::getDirection(), BeingDirection::LEFT, localPlayer, mMoveProgram, LocalPlayer::move(), BeingDirection::RIGHT, settings, tick_time, and BeingDirection::UP.

Referenced by crazyMoveA().

◆ crazyMoveAo()

void CrazyMoves::crazyMoveAo ( ) const
protected

Definition at line 720 of file crazymoves.cpp.

721 {
723  if (settings.crazyMoveState < mMoveProgram.length())
724  {
725  // wear next outfit
727  {
730  }
731  // wear previous outfit
732  else if (mMoveProgram[settings.crazyMoveState] == 'p')
733  {
736  }
737  }
738 }
void wearNextOutfit(const bool all)
void wearPreviousOutfit(const bool all)
OutfitWindow * outfitWindow

References Settings::crazyMoveState, mMoveProgram, outfitWindow, settings, OutfitWindow::wearNextOutfit(), and OutfitWindow::wearPreviousOutfit().

Referenced by crazyMoveA().

◆ crazyMoveAs()

void CrazyMoves::crazyMoveAs ( )
staticprotected

Definition at line 713 of file crazymoves.cpp.

714 {
716  if (localPlayer->toggleSit())
718 }
bool toggleSit() const

References Settings::crazyMoveState, localPlayer, settings, and LocalPlayer::toggleSit().

Referenced by crazyMoveA().

Field Documentation

◆ mDisableCrazyMove

bool CrazyMoves::mDisableCrazyMove
protected

Definition at line 58 of file crazymoves.h.

Referenced by crazyMove().

◆ mMoveProgram

std::string CrazyMoves::mMoveProgram
protected

Definition at line 55 of file crazymoves.h.

Referenced by crazyMoveA(), crazyMoveAd(), crazyMoveAe(), crazyMoveAm(), and crazyMoveAo().


The documentation for this class was generated from the following files: