Guest User

Ignoring Logic

a guest
Mar 9th, 2020
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 1.44 KB | None | 0 0
  1.         while (true)
  2.             {
  3.                 GameFiber.Yield();
  4.                 for (int index = 0; index < 8; index++)
  5.                 {
  6.                     if (Vector3.Distance2D(hotelLocation[index], Game.LocalPlayer.Character.AbovePosition) < 20 ) // Only activate if the player is close enough.
  7.                     {                      
  8.                         Game.DisplayHelp("Menu Should Be activated");
  9.                         if (activeMenu == !true)
  10.                         {
  11.                             mainMenu.Visible = true;
  12.                             activeMenu = true;
  13.                             GameFiber.StartNew(delegate
  14.                             {
  15.                                 while (true)
  16.                                 {
  17.                                     GameFiber.Yield();
  18.                                     _menuPool.ProcessMenus();
  19.                                    
  20.                                 }
  21.                             });
  22.                            
  23.                         }
  24.                        
  25.                     }
  26.                     else if (Vector3.Distance2D(hotelLocation[index], Game.LocalPlayer.Character.AbovePosition) > 20)
  27.                     {
  28.                         // I can't seem to stop this from firing no matter what I do.
  29.                         Game.DisplayNotification("You are away from a hotel.");
  30.                     }
  31.  
  32.                 }
  33.  
  34.             }
Advertisement
Add Comment
Please, Sign In to add comment