Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Isometric endless racing — Gideros Forum

Isometric endless racing

jdbcjdbc Member
edited October 2015 in Game & application design
This is a video of my isometric racing prototype. I have only used sprites as tiles and lua tables to create infinite and random blocks on the road. Isometric tiles from Kenney: http://kenney.nl/assets/isometric-city

Controls are easier: tap to accelerate and do not touch screen to brake.


+1 -1 (+4 / -0 )Share on Facebook

Comments

  • jdbcjdbc Member
    edited October 2015
    I have used these two helper functions:
    -- Get isometric coordinates from cartesian coordinates (x,y)
    function twoDToIso(x, y)
     
    	local isoX = x -y
    	local isoY = (x + y) / 2
     
    	return isoX, isoY
    end
     
    -- Get cartesian coordinates from isometric (isoX, isoY)
    function isoTo2D(isoX, isoY)
     
    	local x = (2 * isoY + isoX) / 2
    	local y = (2 * isoY - isoX) / 2
     
    	return x,y
    end
    Rendering with isometric coordinates and collision in converted 2d coordinates. Tile width and tile height are 64 bits.
    To create the map I have generated 12 blocks and they are added to scene from top to down and left to right. First 6 blocks do not allow transversal roads.
    -- Rendering blocks
    	for a=0,12 do
     
    		if (a > 5) then
    			num = 6
    		end
     
    		local block = Block.new(num)
    		block:setPosition(twoDToIso(0, TILE_HEIGHT * a))
    		table.insert(block_list, block)
    		road:addChild(block)
     
    		num = num -1
    		if (num < 0) then
    			num = math.random(0,3)
    		end
    	end
  • totebototebo Member
    edited October 2015
    Nice, looks great! I want to play it! :)
    My Gideros games: www.totebo.com
  • jdbcjdbc Member
    edited October 2015
    Nice, looks great! I want to play it! :)
    Tomorrow I will upload to the forum a sample apk to test it.
  • Seems really good for the test run.
    A big CongoRatz!!
  • piepie Member
    edited October 2015
    really cool! :)
    it seems a bit "heavy" on galaxy s2 when speed is high: I don't know if it's due to this known bug on android - https://github.com/gideros/gideros/issues/22

    I would try "inverting" the controls to promote adrenaline :D - auto accelerate and press to break
  • jdbcjdbc Member
    edited October 2015
    really cool! :)
    it seems a bit "heavy" on galaxy s2 when speed is high: I don't know if it's due to this known bug on android - https://github.com/gideros/gideros/issues/22

    I would try "inverting" the controls to promote adrenaline :D - auto accelerate and press to break
    Yes you are right, the problem with "heavy" problem it is Gideros version (2015.09).

    I have tested in my Bq Aquaris again with a very previous version (2014.01) and it works smoothly.

    What happens with lastest versions that have worse performance?

    I go back to previous versions at least for Android.
  • Tried it, nice! A bit stuttery when you go fast on my Nexus 6, and the bitmaps are a bit blurred.

    Are you using a spritesheet? If not that can speed things up. And the @2, @3 feature for crisp bitmaps is a winner.
    My Gideros games: www.totebo.com
  • jdbcjdbc Member
    edited October 2015
    Tried it, nice! A bit stuttery when you go fast on my Nexus 6, and the bitmaps are a bit blurred.

    Are you using a spritesheet? If not that can speed things up. And the @2, @3 feature for crisp bitmaps is a winner.
    This is just a prototype, I am using 64x64 isometric tilemaps, so I know that bitmaps are blurred with high screen resolutions. Every bitmap are stored as individual file, I should use spritesheet to improve performance.

    I suppose I will buy Kenney art to get 128x128 images (or even 256x256) from vectorial ones (9$ all assets):
    http://kenney.nl/assets?q=source
  • Hey, pretty cool mate. I would recommend shelling out the few bucks for the Kenney Assets, they are fantastic! You also get all future updates to the pack too which makes it even better :)
  • jdbcjdbc Member
    edited October 2015
    Hey, pretty cool mate. I would recommend shelling out the few bucks for the Kenney Assets, they are fantastic! You also get all future updates to the pack too which makes it even better :)
    I have bought Kenny assets. Isometric tiles that I need are provided as 3D models, I must convert them to images.

    Invert controls, tap to brake and automatic acceleration could be fine, thanks for your ideas.
  • piepie Member
    I tried the other one, it's smoother but it also seems "slower" than the first one. If you put an fps counter I could tell you better. :)
  • jdbcjdbc Member
    edited October 2015
    I tried the other one, it's smoother but it also seems "slower" than the first one. If you put an fps counter I could tell you better. :)
    I have increased now the speed and difficulty so. Controls are inverted, tap to brake and speed up if you do not. I should improve the collision system but its playable for the moment.

    Next days will be first version in Google Play.
  • jdbcjdbc Member
    edited November 2015
    I have just published "Speedy Road" in Google Play. In few hours it will available.
    promotional_image.png
    1024 x 500 - 438K
Sign In or Register to comment.