Project Spikes: 14/09/13 Update

Play it here!

This update has quite a few new features, so give the game a try –  any feedback is appreciated! Firstly, I added a few coloured skyboxes (a skybox is a textured cube that will appear really far in the distance in your game and surround the game world, like a background), with all of World 1’s levels having a light blue skybox.

spikes-6

This is much better than the really horrible basic blue skybox from before. I’ve also done a bit with the GUI, adding some crosshairs and a lives bar at the top with 5 icons representing one life each. If you collect the secret in the level, another icon will appear in the corner, but I will change this in the future.

spikes-7The crosshairs were added to help players sense the direction they’re facing; I will also be adding a shadow for the player to help in the future. One of the green rectangles turn red when you lose a life. I’ve been doing some optimisation of scripts and some modifying of the levels –  they should be more interesting now. One new addition is platforms that will trigger an event when stood on, for example standing on certain platforms will cause it to be influenced by gravity and will fall until it hits something. This may be used in the future as an obstacle for the player. Along with this I’ve added a button that will also trigger certain events when pressed, such as initiating the movement of platforms.

spikes-8

The playable version this time around has fewer levels than before, but they will be added back in later on. This is because I wanted to improve the levels I already had and thought it would be easier to start from scratch. Plus, every level now has a collectible secret in it. I will also be working on more game mechanics to add in future worlds. Also, if you didn’t click the link at the top, here it is again: play the game!

16/05/13 Update- Boxes!

Alpha 0.1.3a Update

I’ve been at work again today, and I’ve finally added crates. They’re pretty basic right now, but I’ll work on them a bit more in the coming days. unity_platformer_26These crates explode when you walk into them, and they expel upto 5 gems. They also release loads of particles that look like miniature versions of the box textures. It kinda reminds me of when you break a block in Minecraft. I really like how these have turned out, and later on I will have different types of crates with different types of pickups, such as health, lives or maybe another collectible. It is also likely that they will not be the only type of destructible container, as I may add items such as jars. Enemies, when added, will also drop gems.

As some people may have noticed, I added a health and life counter in the corner in the last update, but they don’t currently do anything. The next update will focus on this, meaning there will be a way of getting hurt, and there will be a Game Over screen when you run out of lives.  You may also have noticed some gold bars lying about- these may remain simply as decoration, but I could also make these into a second collectible alongside gems, as a rarer find, perhaps only 5 of them in each level.

I’ve also been finding all the bugs in the title screen and I think I’ve squashed them all, so the loading and saving system should be completely flawless now, as well as having 5 slots for game saves and error messages when all slots are full or if you try to enter an empty name under New Game.

Another thing I did, which was actually in the last update, is a title screen, accessed through pressing p. unity_platformer_27You can alter the same options here as you can in the title screen options menu, and if you select ‘Quit Game’, it comes up with a warning. Confirming to quit will take you back to the title screen. I’ve also changed the skybox for the title screen options to something a bit more interesting. unity_platformer_28Now the desert looks like it’s on fire. I like this more than the gloomy overcast look the level had before. This came from a pack of skyboxes I downloaded for free from the Unity Asset store, as is the one I used for the title screen. I don’t remember the name of it but it wouldn’t be hard to track down, and I recommend it, especially to anyone making a space-themed game.

I think I will also start to consider making a proper main character for the game. The red cube is getting a little old now, so I want to make an actual player. I will research around the different ways to do this and hopefully I will find the best way to get the player modeled and animated. Have fun playing with today’s update, found in the usual location. I did want to make a Unity Webplayer version, but it didn’t work for some reason. I will investigate that and hopefully I can get a working version. Thanks everyone!

-Daniel

Day 13 Progress

This is the download link to the latest version of the game:

https://www.dropbox.com/sh/0o38di2thg3x9za/N_CvcxejXT

I’ve been working on making new terrain for the levels in my game. The levels are a bit basic at the moment, and they don’t have many features, but they are much more interesting than what I had before. I have been experimenting with heightmaps and the Unity terrain generation to get better level terrain, and I am happy with the result. I had a few problems initially because using heightmaps in Unity requires .raw files, which are basically image files with very little formatting, and I am using GIMP, which cannot save to a .raw file. I found a program that can convert png files into raw files though, so I got it working eventually. Here’s a tip: if you have Photoshop, use that, it’s as easy as just saving to a .raw file…  hub_world_1

This is the heightmap I used for my hub world. I got this through a quick Google image search but you may want to create your own, like I did for my other levels.

A heightmap is basically a top-down greyscale view of your terrain, with white areas highest up and black areas lowest down, and grey in-between. When this is imported into Unity using the Terrain feature, it automatically creates terrain to match your heightmap. That makes it much easier to create your levels. You can then ‘paint’ your terrain with any texture you want, and bam! You have your basic level. Then you can just add objects in, like scenery, enemies and collectibles, and you have a game. I need to add some enemies and scenery, but I’m happy with my current progress.

I have also been working on getting my character to pick up gems, and it finally works! There is no counter to actually keep track of how many you’ve picked up and they have no function yet, but this will be implemented soon. The way I fixed it is by adding the ‘Rigidbody’ component to the box collider my gem pickup script was attached to, as this allows the ‘OnTriggerEnter’ function in the script to work. Basically this function is activated when any object with a collider component enters the collider of the object I’ve attached the script to, in this case the player. When activated, the script checks for any objects with a “Gem” tag, and destroys it from the game completely. So now you can pick up gems. Yay!

unity_platformer_3

This is the GameObject that handles all the gem grabbing.

I have also made a very simple start screen with two buttons, one to enter the game and another to quit the game. This is made with Unity’s built-in GUI creator. In this title screen, you can also walk around with the player, a feature I want to keep in the final version. It looks like this: unity_platformer_4

When you press the “Quit Game” button, the application will simply close. But when you click the “New Game” button, it will enter the game, starting with the hub world. This has had a few minor changes too: unity_platformer_5

The terrain for this world was made with the heightmap above, and it made a level with a couple interesting mountains as well as a large flat land in the middle. The textures are just default textures provided with Unity, but I will change them to something I like a bit more at a later date. I’ve also added a skybox, which is basically an imitation of a sky, but the camera angle doesn’t let you see it very well. There is a portal in this world leading to “Level 1”: unity_platformer_6

This is supposed to be a desert-like level, but I haven’t had much time to work on it so the textures aren’t complete. The heightmap for this one was entirely made by me though. I’m very happy with the progress I’ve made here, and I hope you will all have fun playing around with this, and if you find any problems or anything you would like added, please don’t hesitate to comment below. Thanks for all the support.

-Daniel