RTS devlog #4: Collision detection and combat

You're viewing a single comment in a conversation. View all the comments
  • 1 Comments

  • Order by
    • [-] [+]
    • 0
    • Ashley's avatar
    • Ashley
    • Construct Team Founder
    • 0 points
    • *
    • (0 children)

    Obviously Construct has built-in collision detection and you can use that from both event sheets and JavaScript coding. But if you want to run in a separate thread you need another solution, and that's what I've done for this project. I could've instead chosen to use the built-in collision detection, but then I couldn't use multithreading, which would reduce the overall performance. I went in to detail about this architecture and its various tradeoffs in the architecture blog post.

    The fact you can even do custom collision detection in a separate thread to the runtime is actually pretty cool I think! It shows Construct's flexibility: use the built-in collisions if you like, or write your own custom implementation in a separate thread. That could then even be split off in to something like a dedicated server running in node.js. Not all tools provide that kind of range of options.