Tonight I added those raisable buildings I was talking about. This involved a lot more work than you’d think! Mostly this was because it’s quite a radical change from the way things are done currently. Each building is made up of several meshes now – a ground floor, a roof, and several middle floors, whereas before there was the assumption that there was a 1:1:1 mapping between building, physics object and mesh.
You may also notice that I’ve thrown some random rotations of buildings into the mix. This pretty much came for free when I was adding in all the other stuff, so I’m happy since it makes things look a whole load more interesting! Similarly, it’ll now be easy for me to add things like stilts/foundations to make sure buildings don’t hover like they can now, or to add scaffolding temporarily just after construction, or to change the appearance of buildings entirely (make them more futuristic as the game progresses or the buildings are developed enough). All graphical niceties that I’ll get to in time!
Unfortunately I’ve broken the physics on those buildings since they can no longer just take their position and orientation from their physics component (otherwise the whole building would be at ground floor level), but I haven’t bothered to fix this since that’s next on my list of things to revamp. I’ll make buildings spawn ‘building chunk’ objects when they collapse, which will improve things in many ways – the Building class will then have one responsibility rather than two (it currently has states for ‘free’ and ‘attached’, the ‘controlled’ state being lost when I factored that out into the ‘Piece’ class), there will be the possibility for multiple building chunks with different graphics to that of the building they came from (proper bits of rubble!), and the Building object will need physics only for collision detection and not to physically attach it to the island.
It looks nice this way! A nice little flying island-supported village.
I’m sure the little island-supported cuboid people are very happy! They must be eagerly looking forward to see these cool upgrades you mentioned.
You broke through the horde of Kotaku posts! Wahey!
Looking good. Can I tempt you to make an iPhone version one day?
Looking pretty good. You could add fancy dynamically generated roads that form based on the distribution of buildings, and evolving technology as time passes… Can you have those in by next week please?
Thanks chaps
They certainly are happy, Chamyky. Since I gave them textures, they’ve all had super-happy faces constantly.
An iPhone version! What a good idea! I’ll make billions!!!
Dynamically generated roads, technology evolution… by next week… well, I’ll have to find something to fill out the latter half of the week but yeah, I’ll get cracking on it