randomkeyhits Posted October 12, 2014 Share Posted October 12, 2014 I've created a disk and attached the standard CollisionTrigger.lua script. While the physics type is prop or scene I can walk into it and the collision event is triggered. The lua script above suggests that you can change the physics type to trigger and the event should trigger without any physics interactions in the scene. For me it doesn't and I can't see a reason why. The only thing i can think of is perhaps the target is not Script:Collision but something else. I've been going round and round with the documentation and forums so has anyone actually successfully done this and did they do something specific to make it work? Quote content over form, game play over all. Link to comment Share on other sites More sharing options...
Haydenmango Posted October 12, 2014 Share Posted October 12, 2014 Trigger Collision Types only collide with Character Collision Types. Check out this if you haven't - http://www.leadwerks.com/werkspace/page/documentation/_/command-reference/collision-r778 Quote Check out my game Rogue Snowboarding- https://haydenmango.itch.io/roguesnowboarding Link to comment Share on other sites More sharing options...
randomkeyhits Posted October 12, 2014 Author Share Posted October 12, 2014 Yes, I saw that thanks. The interaction I used was the player walking onto the disk which once I switched the physics type to trigger I expected it to be the same except for the player would walk through the disk. That and the rest of the documentation tells me it should work, I just can't figure out why not. Quote content over form, game play over all. Link to comment Share on other sites More sharing options...
Haydenmango Posted October 12, 2014 Share Posted October 12, 2014 Yeah that is weird. Hmm does your disk have a mass of 0 and a physics shape? I am not sure what could be wrong other than that. Quote Check out my game Rogue Snowboarding- https://haydenmango.itch.io/roguesnowboarding Link to comment Share on other sites More sharing options...
randomkeyhits Posted October 12, 2014 Author Share Posted October 12, 2014 The disk didn't I added a cylinder shape fit and a mass of 1 but its not made any difference. Thanks for you help though, I'll come back to this tomorrow and see if I can better understand whats happening. Quote content over form, game play over all. Link to comment Share on other sites More sharing options...
Haydenmango Posted October 12, 2014 Share Posted October 12, 2014 Oh I meant that it is supposed to have a mass of 0. Having that cylinder shape you just added and a mass of 0 should make it work. Quote Check out my game Rogue Snowboarding- https://haydenmango.itch.io/roguesnowboarding Link to comment Share on other sites More sharing options...
randomkeyhits Posted October 13, 2014 Author Share Posted October 13, 2014 I'm still not making progress with this The player entity is type character. I deleted and re-created the disk, set the collision type to scene and a shape of cylinder and used shape fit. I attached the CollisionTrigger script and it works ok. Walking into it with the player causes a collision to be triggered. I then change the collision type on the disk to trigger. As expected I do not walk onto the disk but walk through it but now the ColliisionTrigger script is not invoked. Switch the disk back to scene and the collision occurs again. AFAIK this is correct, I just can't make it work. Quote content over form, game play over all. Link to comment Share on other sites More sharing options...
randomkeyhits Posted October 19, 2014 Author Share Posted October 19, 2014 After a lot of experimenting finally made some progress on this. I'm not quite sure why the behaviour is as it is though. I create a plane, place a player on it and a disk 1.5 metre diameter and 1 metre tall. I allow the top 25cm of the disk to appear through the ground. When the object is a scene the player can walk on the disk and a collision is registered. I change it to a trigger and I can walk through it but no collision is triggered. I then raise the disk so that it sat on the plane rather than extruded through it and the trigger collision started working when I walk through the disk. So possibly some sort of clipping/culling thing based on the axis location? I don't know if its intended or a bug or just the way things are but it means that I need to be quite careful in how I specify trigger zones Quote content over form, game play over all. Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.