Hi! I’m trying to make a small game project where the player can hide from enemies when they are in a specific area/hiding place (which are currently part of the level tilemap). Is there any way to temprrarily disable collision between the player when they (the player) are already interacting with a specific collision group?
Sure, something like this:
function on_message(self, message_id, message, sender)
if message_id == "collision_response" then
if message.group == "safe_space" then
msg.post(msg.url(nil, nil, "collisionobject"), "disable")
end
end
end
Both the disable
and enable
properties are available for collision object components.
1 Like