Advertisement
Dieton

DebugMacros.h

Nov 8th, 2023
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.31 KB | Gaming | 0 0
  1. #pragma once
  2. #include "DrawDebugHelpers.h"
  3.  
  4. #define DRAW_SPHERE(Location) if(GetWorld()) DrawDebugSphere(GetWorld(), Location, 25, 12, FColor::Red,true, 30.f);
  5. #define DRAW_SPHERE_SingleFrame(Location) if(GetWorld()) DrawDebugSphere(GetWorld(), Location, 25, 12, FColor::Red,false, -1.f);
  6.  
  7. #define DRAW_LINE(StartLocation, EndLocation) if(GetWorld()) DrawDebugLine(GetWorld(), StartLocation, EndLocation, FColor::Red, true, -1, 0.f,1.f);
  8. #define DRAW_LINE_SingleFrame(StartLocation, EndLocation) if(GetWorld()) DrawDebugLine(GetWorld(), StartLocation, EndLocation, FColor::Red, false, -1, 0.f,1.f);
  9.  
  10. #define DRAW_POINT(Location) if(GetWorld()) DrawDebugPoint(GetWorld(), Location, 15.f, FColor::Red, true);
  11. #define DRAW_POINT_SingleFrame(Location) if(GetWorld()) DrawDebugPoint(GetWorld(), Location, 15.f, FColor::Red, false,-1);
  12.  
  13. #define DRAW_VECTOR(StartLocation, EndLocation) if(GetWorld()) \
  14.     { \
  15.         DrawDebugLine(GetWorld(), StartLocation, EndLocation, FColor::Red, true, -1.f, 0, 1.f); \
  16.         DrawDebugPoint(GetWorld(), EndLocation, 15.f, FColor::Red, true);\
  17.     }
  18. #define DRAW_VECTOR_SingleFrame(StartLocation, EndLocation) if(GetWorld()) \
  19.     { \
  20.         DrawDebugLine(GetWorld(), StartLocation, EndLocation, FColor::Red, false, -1.f, 0, 1.f); \
  21.         DrawDebugPoint(GetWorld(), EndLocation, 15.f, FColor::Red, false, -1.f);\
  22.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement