Advertisement
Guest User

Untitled

a guest
Nov 13th, 2016
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.57 KB | None | 0 0
  1.     unsigned int flags = rwi_stop_at_pierceable | rwi_colltype_any | rwi_ignore_back_faces;
  2.  
  3.     float RayMaxDistance = 100.0f;
  4.  
  5.     hit = gEnv->pPhysicalWorld->RayWorldIntersection(origin, dir*RayMaxDistance, entity_query_flags::ent_all, flags, &rayHit, 1, physSkip, physSkipNum);
  6.     if (hit)
  7.     {
  8.         IPersistantDebug* debug = gEnv->pGame->GetIGameFramework()->GetIPersistantDebug();
  9.         debug->Begin("TestAddDirection", false);
  10.  
  11.         Vec3 lineStart = origin;
  12.         Vec3 lineEnd = rayHit.pt;
  13.         float timeOut = 4.0f;
  14.  
  15.         debug->AddLine(lineStart, lineEnd, ColorF(1.0f, 0.0f, 0.0f), timeOut);
  16.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement