Jump to content

Shiftah - My first LD entry and indeed, my first game!


GaryS
 Share

Recommended Posts

Gameplay.png

Shiftah is not only my first LD entry, but also my first ever game!

I've been messing about with Phaser for a few months now, loving every minute of it... so thought I'd enter Ludum Dare for the first time.
The theme was 'ShapeShift', which just basically screams 'Altered Beast' to me... however with my limited graphical acumen, what I've ended up with is an endless runner style game where you navigate your ship through an onslaught of blocks and shapes, trying not to get stuck.

The physics are a bit shonky, it has to be said - (I could do with a bit of help on that), but as it stands the game is playable.

All in, this was about 30 hours work and includes my first attempts at MOD tracker music too!

You can play the game directly or view my LD submission page.

Link to comment
Share on other sites

Thanks Matt!

Also, thanks for noticing that I've got local storage working on that! As it happens, local storage was really easy. No more difficult than writing a cookie... and if I'm honest, I already had the code to do it laying about.

I've been playing with Phaser for a while, using a basic game as a testbed for techniques and ideas. One of the things I always like to do is write code that can be reusable, and thus I wrote a 'GameData' prefab that handles keeping, updating and displaying stats... scores and the like.
I'd hoped that my prefabs could be dropped into any game I create, and so far that seems to be working well!

As for the blocks, you should be able to slide up and down them... I've had a bit of difficulty there with arcade physics.
As best I can tell, the issue is that the blocks the player collides with are constantly moving, and the collide function aims to move the player back outside of the collision range - this seems to override the velocity that the player happens to have and causes it to stop dead.
Someone suggested I make the collision boundry per row instead of per block, which might work - but will be fiddly to implement.

I've also had a bit of a problem with the movement of the ship... I was trying to be clever with my ship prefab - it has multiple ways of moving - and the best way I could find to allow switching between rotation style movement and basic 8-way movement was to use velocityFromAngle to propel it forward and backwards.
All seemed to work well in testing, but I've found when playing the game that for some reason when rotated to face backwards and moving 'forwards' (relatively, so, backwards), the ship can sometimes move much slower than I think it should.

No idea why that could be!!

Link to comment
Share on other sites

Ah, I see, you're sliding the blocks?

I assumed that the blocks would be static and then it is the camera that moves. I don't know anything about arcade physics but naturally you should be able to slide against a surface (which would take into account friction) and that is far easier when one of those objects is static, like sliding against a wall, it would be significantly harder to slide laterally if the wall was pushing back towards you. This reduces your physics logic too as static objects are far far cheaper to model.

Writing reliable and robust reusable code is key.

Yes local storage is very easy and its pretty much ubiquitous now so little reason not to use it, its certainly easier than faffing with cookies. I actually have a system going (not particularly useful for fast paced games) that uses a centralised state object (all of the state for you app is in one place), when there is an error it pings the entire state tree into local storage (if it can, there are limits on local storage), from there I can grab the state tree and use it to exactly replicate the state that caused the error. No more faffing with a complicated set of replication steps, just grab the state and reproduce the error. 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...