phreaknation Posted September 14, 2015 Share Posted September 14, 2015 So I have a question. Is there a way to basically not have the camera stop by the world borders? Is there a way to disable the world borders or something? Basically I have a HUGE world map that I basically want players to free roam in. I do not want to load the entire map in but rather have the map load and render in as needed. The bad part is that the map data is coming from google maps so there is no real left or right. If you could help me solve this by disabling the world map border, or even some other method that would be awesome. I have thought about shifting the map its self but that might take some hefty render cycles to move the map and entities in the map Link to comment Share on other sites More sharing options...
wayfinder Posted September 15, 2015 Share Posted September 15, 2015 this.world.bounds.x = -Infinity; this.world.bounds.y = -Infinity; this.world.bounds.width = Infinity; this.world.bounds.height = Infinity; this.camera.bounds.x = -Infinity; this.camera.bounds.y = -Infinity; this.camera.bounds.width = Infinity; this.camera.bounds.height = Infinity; Link to comment Share on other sites More sharing options...
phreaknation Posted September 16, 2015 Author Share Posted September 16, 2015 Gave that a shot and it actually breaks the game entirely. At least the world bounds. The particle generator which I use for weather effects only goes down the Y axis and ignores the X. However I just used the camera bounds and it seems that might work I just need to fix my hotbox to work with negative numbers Link to comment Share on other sites More sharing options...
phreaknation Posted September 16, 2015 Author Share Posted September 16, 2015 Got it resolved. the mouse sprite had collideWorldBounds set to true. Will not be able to have that set for everything. Will need to see if that reacts to other game objects as well. Thank you for your help. Link to comment Share on other sites More sharing options...
Recommended Posts