Isometric look code

Previous topic - Next topic

Wampus

Isometric look - code and some notes



You can download a compiled sample app here: http://www.mediafire.com/file/sr8z51bbwe8d96f/isometricdemo.app.zip
Instructions for the compiled app here: http://www.glbasic.com/forum/index.php?topic=8151.0

Attached to this post is the source code.

There isn't much notation at all about what does what. I used TexturePacker for packing the textures (exporting as Gideos format). The layers of blocks were made with SimpleTileEditor. I wasn't intending this for general release, just a proof of concept after I had the idea. Sorry if the code is not very accessible.

[attachment deleted by admin]

MrTAToad

#1
I'll see what it's like on Android :)

Its not bad at all - it could be a good alternative to 3D

erico

Quote from: MrTAToad on 2012-May-25
Its not bad at all - it could be a good alternative to 3D

Yep, it would be nice to have a solution for sprites too or maybe diagonal blocks.
Maybe the engine can be adapted to work the same way on a kind of ´voxel´ sprite?
just some thoughts, I read the code later to catch an idea.

Wampus

A sprite function was something I was going to put in but didn't have time yesterday. Shouldn't be too hard though. I have the photoshop template ready for constructing them. I don't have much knowledge about real voxels. However, there are some more ways the routine can be optimised.

I tested the routine on Android and was surprised at how quick it was on weaker devices. Because of that I am now intending to improve the engine and create a basic game with it. Fun stuff.

fuzzy70

Love the effect Wampus, Am working on an Isometric routine myself although nowhere near as smart looking as yours  :nw:

Lee
"Why don't you just make ten louder and make ten be the top number and make that a little louder?"
- "These go to eleven."

This Is Spinal Tap (1984)

erico

Quote from: Wampus on 2012-May-25
...Because of that I am now intending to improve the engine and create a basic game with it. Fun stuff.

Please DO! :good:

bigsofty

Little late to the party but this looks very nice, it's screaming for some sort of RPG or turn based game. Well done!  :good:
Cheers,

Ian.

"It is practically impossible to teach good programming style to students that have had prior exposure to BASIC.  As potential programmers, they are mentally mutilated beyond hope of regeneration."
(E. W. Dijkstra)

MrTAToad

Or some improvement on Minecraft!

Albert

I've played a lot of this code.
Added vertical camera tilt, fixed half bricks topside render problem and added shade (press SPACE to toggle)

download: http://dl.dropbox.com/u/292449/glbasic/iso/isometricCODE.zip




erico

gasp cough :O
I guess I will just pack up and move to the country side and go plant potatoes...

...really great feats coming from this!

Albert

We want an editor!

Albert

#11
Android version: http://dl.dropbox.com/u/292449/glbasic/iso/glbasic-debug.apk
Rotate: touch and drag or fling
Zoom: touch the left side of the screen and drag up/down
Toggle shade: touch the upper-left corner of the screen

MrTAToad

Runs very fast on my Android phone, although the screen size was set to be something larger than 320 x 480 :)


Albert

I've made a simple editor (using my IMGUI library)

Download for WIN32: http://dl.dropbox.com/u/292449/glbasic/iso/isometricEditor.zip
Download for Android: http://dl.dropbox.com/u/292449/glbasic/iso/isometric-editor.apk
With this large map Android version is running with lower FPS here when 'shaded' enabled, and running with full FPS if I disable it (Samsung Galaxy S), use the controlls on the window named 'settings'.


metzzo

Hey!

I wanted to see if GLBScript is capable of compiling and running this nice piece of code. Compiling was no problem and for executing I had to fix some bugs (mainly related to POLYVECTOR)

Here is the running example: http://programming-with-design.at/files/GLBScript/Isometric/GLBFile.html
Sadly Firefox is really slow, but Chrome seems to be the fastest (InternetExplorer does not even start...)
That's no Bug, that's my project!

http://programming-with-design.at/