Advertisement
Tkap1

Untitled

Jul 28th, 2022
1,072
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.73 KB | None | 0 0
  1. // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv     THIS        vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
  2. struct Rendering
  3. {
  4.     //...
  5. };
  6.  
  7. struct GameState
  8. {
  9.     // ...
  10.     Rendering rendering;
  11.     // ...
  12. };
  13.  
  14. static Rendering* rendering;
  15.  
  16. static void update_game()
  17. {
  18.     // ...
  19.     rendering = gameState->rendering;
  20. }
  21. // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^     THIS        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  22.  
  23.  
  24.  
  25. // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv     VS THIS vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
  26. struct Rendering
  27. {
  28.     //...
  29. };
  30.  
  31. struct GameState
  32. {
  33.     // ...
  34.     // ...
  35. };
  36.  
  37. static Rendering rendering;
  38.  
  39. static void update_game()
  40. {
  41.     // ...
  42. }
  43. // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^     VS THIS ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  44.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement