Hilfe
Parameter
-
Rückgabewert
-
Beschreibung
Mit ClearCollisions wird die Kollisions-Liste gelöscht.
Immer wenn der Befehl Collisions benutzt wird, um die Kollisionsprüfung zwischen zwei Objekten einzuschalten, wird auch eine Kollisions-Liste im Speicher abgelegt. Mit dem Befehl ClearCollisions wird diese Liste wieder gelöscht - bis noch mal der Befehl Collisions
ausgeführt wird.


Beispiel
Standardbeispiel:
SetBuffer BackBuffer()
camera = CreateCamera()
light = CreateLight()
sphere = CreateSphere(32)
PositionEntity sphere, - 2, 0, 5
cone = CreateCone(32)
EntityType cone, type_cone
PositionEntity cone, 2, 0, 5
type_sphere = 1
type_cone = 2
EntityRadius sphere, 1
EntityType sphere, type_sphere
EntityType cone, type_cone
Collisions type_sphere, type_cone, 2, 2
While Not KeyHit(1)
x# = 0
y# = 0
z# = 0
If KeyDown(203) = 1 Then x# = - 0.1
If KeyDown(205) = 1 Then x# = 0.1
If KeyDown(208) = 1 Then y# = - 0.1
If KeyDown(200) = 1 Then y# = 0.1
If KeyDown(44) = 1 Then z# = - 0.1
If KeyDown(30) = 1 Then z# = 0.1
MoveEntity sphere, x#, y#, z#
If KeyHit(57) = 1 Then ClearCollisions
UpdateWorld
RenderWorld
Text 0, 0, "Benutze die Cursortasten sowie A und Z"
Text 0, 20, "Mit Leertaste Kollision ausschalten"
Flip
Wend
End
Siehe auch

