Tuesday, 28 October 2014

Teleport and other updates

 Over last week I have implemented a number of different features such as teleports, scores, fixing movement and collisions for players, mini-maps.

 First of all I added particle effects to make teleports look as a magical portal and I have also made a teleport prefab that can be easily dragged into the scene and adjusted in lots of ways keeping all teleport mechanics as it should be.

 I have encountered one major problem with implementing teleport script to change player location when he enters teleport trigger area. As the player has Rigidbody attached it made the main character rotate as crazy after just basic position change. I manage to find an algorithm for this online here. Applying the second algorithm solved the problem and even though I used ready algorithm I wrote the rest of the code myself. This improved my knowledge about Rigidbody component as I have never used them before in my last game (at least not for player character).


 Basically this time I ended up writing simple 3rd person character controller without realising it! I had some other problems with main character movements and collision detection which I solved by using Rigidbody friendly script methods and variables.


 I also added basic score counter for both the shadow and the main character so now it displays both on the screen and I made sure it counts it correctly. Score system uses private variables and get and set methods to access it from different scripts. If I have time later on I will try to implement get and set methods for every variable in scripts that will be accessible through the Inspector in Unity.


 I have also added teleport mini-map pointer to teleport prefab so now-main character, shadow and teleports have their pointers on the mini-map. Next thing I will add to mini-map is border to make it easy to recognize which mini-map is which...

 Next things to implement are as follows: collectable items, traps, 3D models that will make scenery look good, mini-map border, sounds and I need to think about the main goal of the game…

Tuesday, 21 October 2014

Minimap Part 1

 I decided to create two minimaps-one for main character and the other for the shadow in order to make my game less confusing.

To achieve that I added 2 more cameras that I put on the front layer of the game screen. As well as this I've added pointer cubes with self-illuminative material on both- main character and a shadow. These are not visible by cameras attached to players and do not affect game world in any way other than showing the position on the minimap.

As for the minimap there is one more feature I want to implement, that is putting a border around it to distinguish two minimaps easily.

Thursday, 16 October 2014

Progress overview..

Implementing core game mechanics led to couple problems, but most of them are solved now.

First issue I encountered was making a shadow a trigger that will rotate a player. First iteration of this script didn't work for couple reasons. Eventually I managed to solve this problem. As I read through Unity Script Reference and there seemed to be couple solutions, there was only one that worked.

Then I had a few problems with detecting if player triggered the shadow so that it rotated him.

Split screen start view
After this I changed the controls and movement script to make it my gameplay easier.

I also changed the way rotation was triggered. The script now counts the distance between players. And if main character is in specific range of the shadow it will start rotating.To stop rotation space need to be pressed by the main character and all other controls are disabled until then.



Next thing I to implement will be Minimap to make it easier to move around the world.

Tuesday, 14 October 2014

Starting on game mechanics

Yesterday I managed to get the core game mechanics work. My first idea on how to implement it worked quite well although I will keep working on this script to improve it in the next couple days.

Having this done I can now move on to adjusting the rotation sensivity and also creating surrounding area.

I am also considering creating some pickable powerups boosts etc. As well as this I have to decide whether to use split screen or not. Using one screen for both players will increase the difficulty of the game although it may get too confusing...

More updates coming soon! :)

Monday, 13 October 2014

Dancing with Shadows-new game project idea

I got this game idea for quite a while now. I came up with it couple months ago. This term we have to make game using two different sets of controls so that two players can play it at the same time.

Therefore I decided to adjust this game idea into that concept. One player will be main character that has to escape from the shadow(the other player whose task is to follow and try to catch main character).

When shadow catches the main character, he confuses him by changing his rotation. The first idea on how to achieve this game mechanics working is to make a shadow a trigger and write appropriate script when main character enters the trigger. Hopefully I can get this done in next couple days.

I already have a movement scripts for both players although it may need changing later on as it is only basic movement script. More updates coming soon.