Since it's a rectangular object, I need additional boxes spawned in the front and back. IT works for a non-moving object perfectly, as the invisible squares and the original model size matches the visual quite nicely.
Code: Select all
TNT1 A 0 A_SpawnItemEx("Collision", 54, 0, 0, 0, 0, 0, 0, SXF_NOCHECKPOSITION)
TNT1 A 0 A_SpawnItemEx("Collision", 0, 0, 0, 0, 0, 0, 0, SXF_NOCHECKPOSITION)
TNT1 A 0 A_SpawnItemEx("Collision", -54, 0, 0, 0, 0, 0, 0, SXF_NOCHECKPOSITION)
So how do I go about this ? Can anyone guide me or even write something which I can add to my actor ?"Spawning something every frame? What is this, the ice age?The collider would be spawned only once, storing its "spawner" in a pointer. ZScript lets you do this stuff conveniently. Yeah, sure the actor count would go up, but you don't have to spawn something every frame is my point."
Another question: How can I make these collision boxes be ... well ... sensitive ? Like damaging them damages my actor ( because if the projectiles hit from behind or front, they crash into the coll box and the actor is undamaged)