| Blockland Forums > Modification Help |
| Finding what a vehicle hits |
| << < (2/5) > >> |
| elm:
--- Quote from: Treynolds416 on June 08, 2012, 11:03:59 PM ---%obj is the jeep Would %this be the datablock of the thing it hit? --- End quote --- No it is the drifting vehicle. |
| Treynolds416:
--- Quote from: Port on June 08, 2012, 11:16:53 PM ---%col is what the object hit. http://docs.garagegames.com/torque-3d/reference/classShapeBaseData.html#a20b5fdadf24208cf5e7ef53d0242747c --- End quote --- That's what it should be, but %col is always 0 every time, no matter what is actually hit. --- Quote from: elm on June 08, 2012, 11:17:08 PM ---No it is the drifting vehicle. --- End quote --- No stuff |
| Port:
--- Quote from: Treynolds416 on June 08, 2012, 11:28:11 PM ---That's what it should be, but %col is always 0 every time, no matter what is actually hit. --- End quote --- Well, if it's 0 you won't be able to find the collided object. The zeroth parameter (auto-assigned by namespace) is the datablock. The first parameter is the object which triggered a collision. The second parameter is the object which the first parameter collided with. The third parameter is the location where a collision was detected. The fourth parameter is the vectorLen of the velocity of the first parameter at the point of collision. |
| elm:
--- Quote from: Treynolds416 on June 08, 2012, 11:03:59 PM ---Would %this be the datablock of the thing it hit? --- End quote --- No stuff? Your question doesn't look like one of no stuff.. |
| Treynolds416:
--- Quote from: Port on June 08, 2012, 11:32:47 PM ---Well, if it's 0 you won't be able to find the collided object. The zeroth parameter (auto-assigned by namespace) is the datablock. The first parameter is the object which triggered a collision. The second parameter is the object which the first parameter collided with. The third parameter is the location where a collision was detected. The fourth parameter is the vectorLen of the velocity of the first parameter at the point of collision. --- End quote --- The third is the velocity vector, I just said that. Any reason why the collided object is always 0? Any ways around it? --- Quote from: elm on June 08, 2012, 11:34:21 PM ---No stuff? Your question doesn't look like one of no stuff.. --- End quote --- Oops my bad elm, thought you were telling me that %obj was the drifting jeep when I had just said it was the jeep |
| Navigation |
| Message Index |
| Next page |
| Previous page |