2 Replies Latest reply on Oct 1, 2011 9:45 PM by TG-Bionic- RSS

    PCDev : PhysicsTrace help?


      I'm porting Frontlines from COD4 to Black Ops but I'm having problems with the physicstrace function since it's not work like used to work in COD4 and I'm a little lost about that...

      In COD4 physicstrace ( pos1, pos2 ) returns the position (x, y, z) where we have a collision between the 2 given positions.

      But in BO returns a structure, which I still don't know exaclty all that comes with, but we can't use that to what I need, find the Y value of the result.

      I found out after some time that if I did this var = physicstrace ( pos1, pos2 ); I can get the position as var["position"] in the format (x, y, z), but the position which came it's ALWAYS the initial position (pos1) which I already know and don't need.

      Can you give me more info about how PhysicsTrace works in BO? structure? how to get the collision position? or simply forget this function and if there's another one that could give me what I need?

      thank you!
        • Test #1
          Re: PCDev : PhysicsTrace help?
          seams it's doesn't work... for a simple test, I simply added 150 in y of the player position, then tried to trace from that position until player position -150 in Y. still keeps me giving the original position, dunno why. seams it's broken, or the object to trace it's too fat (large) that can't be inside these 2 points or something. weird.

          well, I tried with bullettrace instead and works like physicstrace in COD4, works perfect as I wanted...

          I'll use for now on bullettrace instead...

          thanks anyway for the fast reply PCDev.
          Last Edited: Sep 15, 2011 2:58 PM
          • Test #1
            Re: PCDev : PhysicsTrace help?
            Hi how are you today
            Last Edited: Oct 1, 2011 9:45 PM