Page 1 of 3

Cubenemy : Android game

Posted: Wed Jun 11, 2014 6:25 am
by fracteed
I was going to start a mini dev log of my progress on my first ZGE game on here. It is actually my first 3d game , but as I have created several 2d games previously and am experienced in 3d, it is not too much of a stretch :D ZGE is making it a nice easy transition...

The game is called "Cubenemy" and is being developed specifically for Android small screen sizes with very simple controls as I hate onscreen buttons! The concept is very simple, with the aim to avoid oncoming obstacles/enemies and pickup ammo to destroy them when possible. This negates the need for having a separate fire button as the ammo only lasts a short burst before having to pick up another.

I think of it somewhere between the simple one button avoidance phone games of today mixed with the classic 80's scrolling shooters. A mashup of Galaga and Jetpack Joyride if you will :)

Free Android version at the Google PlayStore: https://play.google.com/store/apps/deta ... d.cubenemy

Windows version download at my site:
http://fracteed.com/cubenemy.html

Posted: Wed Jun 11, 2014 3:16 pm
by Rado1
Fracteed, screenshots are looking great, looking forward to the apk or exe.

Posted: Thu Jun 12, 2014 8:17 am
by VilleK
Yeah looks cool :). It would be great with more ZGE-powered games on Google Play so good luck with it.

Posted: Thu Jun 12, 2014 8:39 am
by fracteed
Thanks Rado and Ville! I am having fun with it, just need to find more time to put into it. Loving how easy it is to export and test to Android from ZGE.

My aim is to do a cut down version freebie for the Google Play store initially. Then keep working on tons of levels for either a paid version or an ad supported one. Was thinking of trying to wrap an apk from ZGE with appwrapper for ad support. Not sure if anyone has tried that or not?

And yeah, I will post an apk/exe on here in the near future. It is still very WIP at the moment.

Posted: Mon Aug 18, 2014 11:22 pm
by fracteed
I have been very sidetracked on other projects, but just a small update on where I am up to with Cubenemy.

- I have attached a more recent screenshot of a current build. As I abandoned any notion of writing my own shaders for glows, I ended up using a very simple technique of creating glowing shapes in gimp or inkscape and using them as a texture with alpha on quad planes in ZGE. Then it is just a matter of layering up several planes and parenting them to objects. A little trickier when the object is rotating, but just a matter of creating the correct hierarchy. Since my game is 2.5d and has a fixed camera this works really well.

- Since there is no support for animated sprites, I came up with a technique that I am using for the particle streak effect around the player ship. After creating an animated loop for the particles in a 3d package, I rendered this to a horizontal sprite sheet. Then I mapped this to a square plane in ZGE and used an expression to offset the uv's each frame. There are some limitations with this technique but in general it works really well and I intend on using this for other animated sprites.

- I added 2 levels of parallax with some offset scrolling backgrounds and a 3rd level for star particles. Not using the particle system, just creating and destroying images mapped to quads. This gives much more of a feeling of depth and since the BG offset amount remains constant between levels, there is no break visible to the player even though all models are destroyed/recreated between levels .

Posted: Tue Aug 19, 2014 7:07 am
by VilleK
Very nice screenshot! Thanks for telling us about your progress. Time for a YouTube clip soon maybe? :)

Posted: Tue Aug 19, 2014 7:20 am
by fracteed
Thanks Ville :) Yeah, I really need to get my act together with a website and youtube channel etc. Was never good at that side of things...I have enough trouble getting motivated to just update my twitter feed!

Posted: Wed Aug 20, 2014 1:57 pm
by jonaspm
Nice looking game fracteed!!! Keep up the good work ;)

Posted: Wed Aug 20, 2014 10:26 pm
by Imerion
Looks fantastic! Would love to be able to do those glow effects. I think I am doing something similar in the game I'm curently working on, but yours look a lot better.

!

Posted: Sat Aug 23, 2014 11:53 pm
by fracteed
Thanks for the comments guys :) Imerion, to do the glow effects I am just using a meshbox(quad2d) with a basic feathered circle rendered from Inkscape. If you use Alpha/One mode in the material settings it will give you that very blown out effect as it is additive. Parent the quad to your geometry via the render transform group and you are good to go...very simple but effective! Of course the planes need to face the camera and you need to setup your expressions accordingly.

I have attached a png that I am using for half of my glows. It is amazing how much use you can get from one image when you scale and layer it. Tends to look like a different hue depending on which geo it is being added over.

Re: !

Posted: Sun Aug 24, 2014 12:46 am
by Kjell
Hi fracteed,
fracteed wrote:I have attached a png that I am using for half of my glows.
Alternatively you can use the BitmapExpression component to generate such texture procedurally ( which saves a couple of bytes ), it's ZGameEditor afterall ;) For example ..

Code: Select all

<?xml version="1.0" encoding="iso-8859-1" ?>
<ZApplication Name="App" Caption="ZGameEditor application" CameraPosition="0 0 2">
  <OnRender>
    <UseMaterial Material="GlowMaterial"/>
    <RenderSprite/>
  </OnRender>
  <Content>
    <Bitmap Name="GlowBitmap" Width="3" Height="3">
      <Producers>
        <BitmapExpression>
          <Expression>
<![CDATA[// Set color to white ( yellow hue is done using Material )

Pixel.R = 1;
Pixel.G = 1;
Pixel.B = 1;

// Calculate alpha using sine driven by radius from center

float u, v;

u = 0.5-X;
v = 0.5-Y;

Pixel.A = sin((1-sqrt(u*u+v*v)*2)*PI/2);]]>
          </Expression>
        </BitmapExpression>
      </Producers>
    </Bitmap>
    <Material Name="GlowMaterial" Shading="1" Color="1 0.84 0 0.78" Light="0" Blend="2">
      <Textures>
        <MaterialTexture Texture="GlowBitmap" TexCoords="1"/>
      </Textures>
    </Material>
  </Content>
</ZApplication>
K

Posted: Sun Aug 24, 2014 10:17 am
by Imerion
Thanks for the suggestions! Sounds good, I'll try implementing it in my game.

Posted: Sun Aug 24, 2014 11:35 pm
by fracteed
Thanks for the code Kjell :D I was initially considering using something like this, but ended up cheating by using Inkscape! It is funny that I am using a procedurally orientated engine to do a game with almost no procedural graphics. I will file away your code for use in the future...

Posted: Mon Aug 25, 2014 10:38 am
by Kjell
Hi fracteed,
fracteed wrote:It is funny that I am using a procedurally orientated engine to do a game with almost no procedural graphics.
Don't worry, you don't have to use procedural techniques if you don't want to :wink:

K

Posted: Mon Aug 25, 2014 11:41 pm
by fracteed
It is not that I don't enjoy the procedural workflow. In my day job I love putting together procedural setups in tools like C4D, Houdini, Ice etc. It is just that when I have to do it purely in code, that I often hit a wall.

For me, the ideal workflow for proceduralism is a mix of nodal networks and bits of code to glue it together. Would love to see ZGE develop more towards the nodal side. The mesh component is a good start, but relies very heavily on the mesh expression to do all the heavy lifting. Likewise if the shading/texturing workflow went in a nodal direction, it would be much more usable. Anyway, I realise this is a one man project so I don't have unrealistic expectations!

I am forcing myself to learn more of the shader code workflow as I really need it in a 2d Gamemaker game that I have been working on for a while. Slowly but surely getting my head around it :)