rameshvarun / netplayjs

Make P2P multiplayer browser games, no server hosting or synchronization code required. Powered by rollback netcode + WebRTC.
https://rameshvarun.github.io/netplayjs/
ISC License
496 stars 34 forks source link

Allow canvas reference in Game constructor #80

Open jackwlee01 opened 1 year ago

jackwlee01 commented 1 year ago

P5.js would be an ideal library to use with netplay.js, but it creates it's own canvas element. https://github.com/processing/p5.js/issues/1477

Could you allow passing an existing canvas element into the Game constructor?