bbEntityCollided confusion

Archives Forums/Blitz3D SDK Programming/bbEntityCollided confusion

Bukky(Posted 2007) [#1]
Hey guys,

I'm going through a Blitz3d tutorial using BlitzMax and Blitz3d SDK. I ran into a bit of confusion though. What exactly does bbEntityCollided return?

The commands.html file which ships with Blitz3d SDK describes bbEntityCollided as returning "the handle of the entity of the specified type that collided with the specified entity". That's fine, but then a few lines down it states, contradicting the previous statement, that:

"bbEntityCollided provides a simple alternative in situations where a simple True or False collision result is required in regards to the specified entity type."

What gives? Ideally I want a true or false value. Should I be using a call other than bbEntityCollided for this purpose?

Here is the code where I'm trying to use it:

Function touchground(n$)
	If Not bbEntityCollided(n$,SCENERY)   
		bbPositionEntity (n$,bbEntityX(n$),bbEntityY(n$)-0.01,bbEntityZ(n$))
	End If
End Function


The error that I get is "unable to convert from String to Int".


Bukky(Posted 2007) [#2]
Never mind, got it working, just got rid of the '$'.