thomasboyt / coquette-inspect

A Chrome DevTools extension for inspecting games made with the Coquette framework

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Inspect entity at cursor

thomasboyt opened this issue · comments

This one's pretty out there, but I think it's doable, if prone to breaking in intense ways:

Any entity in Coquette's collision detection framework should have this.size{x,y} and this.center{x,y} properties that could be used to determine whether two x,y coordinates lie within an entity. In fact, Coquette even has a super awesome method built in for this, used like this in the spinning shapes demo.

The debugger could have an "inspect at cursor" toggle, almost exactly like the inspect element button in the DOM inspector, that would allow you to click an entity and open its particular tree.