ruslanfan

WIP DuckDuck

Recommended Posts

Hello everyone!

I am working on a game for two players. Mechanic is simple, players starting from center and move to opposite direction by hitting left or right arrow button. The winner is who first will reached edge of screen.

Here is working demo

image.thumb.png.06c4f8379087c00c4414a4461ee205b5.png

Yeah, visually game is far away from nice and cool, but i think i am in right direction.

I will try to not forget to write posts in this topic.

💜

Today i kinda proud of myself for this "for loop" because it's short and smart ha-ha 

 for(i=0;i<move.length;i++){
            for(k=0;k<move.children[i].length;k++){
                game.add.tween(move.children[i].children[k]).to({
                    x:width/2,
                    y:height/2,
                    width:0,
                    height:0  
                }, game.rnd.integerInRange(1000,5000), ease, true);
            }
        }

Just look at this before and after:

image.thumb.png.7dc0789b79611b0eec9e7b4fb893c74f.png

 

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.