Advertisement
Guest User

Untitled

a guest
Jun 16th, 2019
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.13 KB | None | 0 0
  1. if (me->isInFront(&movePos))
  2. {
  3. pos_x = me->GetPositionX();
  4. change_x = movePos.GetPositionX();
  5. }
  6. else if (me->isInBack(&movePos))
  7. {
  8. push_front = true;
  9. pos_x = movePos.GetPositionX();
  10. change_x = me->GetPositionX();
  11. }
  12.  
  13. if (me->isInLeft(&movePos))
  14. {
  15. pos_y = me->GetPositionY();
  16. change_y = movePos.GetPositionY();
  17. }
  18. else if (me->isInRight(&movePos))
  19. {
  20. push_front = true;
  21. pos_y = movePos.GetPositionY();
  22. change_y = me->GetPositionY();
  23. }
  24.  
  25. for (float i = pos_x; i < change_x; i += SIZE_ONE_CAGE)
  26. {
  27. if (me->GetEntry() != NPC_CHESS_HORSE || me->GetEntry() != NPC_CHESS_ROOK)
  28. if (abs(pos_y) - abs(change_y) > 5.0f)
  29. if (pos_y < change_y)
  30. pos_y += SIZE_ONE_CAGE;
  31.  
  32. pos.m_positionY = pos_y;
  33. pos.m_positionX = i + 0.2f;
  34. push_front == true ? tempPos.push_front(pos) : tempPos.push_back(pos);
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement