Skip to content
GitLab
    • Why GitLab
    • Pricing
    • Contact Sales
    • Explore
  • Why GitLab
  • Pricing
  • Contact Sales
  • Explore
  • Sign in
  • Get free trial
  • Solarus GamesSolarus Games
  • SolarusSolarus
  • Issues
  • #551

Wrong collision detection between custom entities and switch/crystal

Created by: christopho

Here is a sample of code for a custom entity (the arrow) :

self:add_collision_test("sprite",function(me,collision_entity)
  print(collision_entity:get_type());
end)
self:add_collision_test("touching",function(me,collision_entity)
  print(collision_entity:get_type());
end)
self:add_collision_test("overlapping", function(me, collision_entity)
  print(collision_entity:get_type());
end)

If the collision_entity is a solid switch (type "arrow solid" or "solid") or a crystal, only the sprite collision works.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking