-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
@evilfer
I was wondering whether it was possible to expose velocity property in sprite body for binding. So you can bind it to state values instead of directly setting it on context nodes.
I noticed that you have exposed body properties as prefixed properties https://github.com/evilfer/react-phaser/blob/master/src/impl/properties/custom/body.js#L9-L10
How do you extend this to support velocity which it itself a object with x/y properties.?
Also is it possible to have body as a nested property of sprite with all attributes of physics body exposed on it instead of using prefixed approach.
<sprite>
<body>
<velocity x={this.state.playerXVelocity}/>
</body>
</sprite>
Metadata
Metadata
Assignees
Labels
No labels