GA Spring 2023 – Lizard Lick

Lizard Lick


One Person Production

The game’s main objective is to eat as many bugs as you can within the rounds time limit beating the previous highscore.

This simple and clear game-idea would make it easier for one person to cover both the artsy and the programming side.

There was both positive and negative cosiquences from doing the project alone: I could deside all the functions and the outlook of the game.

I quickly noticed that this helped me with having a clear and simple idea and all the pre-production was easy.

The artsy-side took a massive fail and the game looks like a sarcastic remake of a 2005 miniclip game. I made quick mock-up sprites for my game objects, that I tought I would later update to look nicer,

-I never updated them.

To be fair, I did make lots of these horrible low-poly models in blender. I played around with lots of different textures but it never looked good. Here’s a couple examples from the head:

Also I ended up really liking the 2d drawing mock-up I used for a “placeholder”, so it ended up being the final version.


Game Features

Since I had the clear vision in my head, but some of the implementing fell short, I am going to explane the planned features, implemented features and features to implement in the future in three different sections.

Planned Features

  • Lizards eye movement
  • Tongue auto-following the cursor
  • Bugs moving on the screen
  • Timer for the round
  • Score counter for how many bugs eaten within the time limit
  • High score indicator
  • Leaderboard

Implemented Features

  • Bugs moving on the screen
  • Timer for the round
  • Score counter for how many bugs eaten within the time limit
  • High score indicator
  • Tongue auto-following the cursor

Future Features

  • Lizards eye movement
  • Leaderboard (with name input)
  • Easy, medium and hard mode
  • Multiplayer
  • App implementation
  • Infocards between rounds showing info about different reptiles
  • “Un-lockable” new lizards, also corresponding environments and bugs
  • Bugs moving more naturally, trajectory curves
  • SaveSystem
  • Maybe minigames(?)
  • Credit scene
  • More coheesive audio

How the features were implemented?

Bugs moving on the screen

I am quite proud of this one. The bugs needed a spawner-object that I could plant all around the lizard. This fly-spawner would pool as many flies as was set, for example 5, and shoot them on the screen. After the flies lifetime was over, the objects would get recycled and used again. Just like in the Spaceshooter’s asteroid example in Sami’s lecture. Since it really does not matter at the end for the game, but was just a reminder for me that I am learning something about programming.

In the future I want to change the flies trajectory into curving lines, so that they would not just shoot in a straight line. Sadly I didn’t have enought time for it now, but I have an idea maybe using Bezier curves.

Also a problem arose when I started to program the point counter. I thought the “point added” sound-effect would make sense to be attached to the actual fly script. But since the game object gets destroyed at the exact same time that the “point added” sound-effect should play, it won’t play the sound-effect… This was followed by many, many, null reference exceptions. This was resolved by adding the sound-effect to the ScoreManager script.

Timer for the rounds

The whole timer ordeal was more simple than I originally tried to make it. In the end I followed instructions from GameDevBeginner’s article.

Basically, storing a float time value and subtracting the duration of the last frame, every frame to make it count down. Then the float time was divided by 60 to get the minutes before using the modulo operation ( dividing again) to get the seconds. Finally FloorToInt rounds each value down and string.Format displays them correctly in a text field.

Score counter and High score indicator

This got a little messy to be honest. First I stored the highest score in player prefs, eventough I was in the process of building better SaveSystem to store all the data in a binary form. Also there arose some more problems, since the point counter was implemented in the flies script and not in the player lizards script. For the point counter and high score I followed Coco Code’s quide.

First mistake was when the AddPoint method came from the flies OnMouseDown function. Now looking back I should have implemented the AddPoint coming from the Lizards script. Anyhow, after the point is added, the ScoreManager stores this value and compares whether its higher or lower than the previous score. Previous high score is displayed above the players score count in the in game state.

Tongue auto-following the cursor

This was the last feature I implemented and it almost did not make the cut. I had a clear vision of having two points, one in the mouth of the lizard, one attached to the mouse position. And in between I would use a line renderer. This way it would look as the tongue would stretch to where the cursor moves… But time after time I would just see null reference exceptions. It would not work. Luckily one day before the final presentation a senior student would help me resolve this issue.

The problem was that the camera was never defined 😀 So I tagged the camera as main camera and tadaa -it worked. There is still this weird perspective warp happening when moving the mouse sometimes, but it works fine.

Features that never made it… But was so close.

Save System

I started to program a SaveSystem that would save player name, score and position on the leaderboard. Did not have enough time to finnish this tho. For now there is only the temporary player pref high score saved.

The Leaderboard

The leaderboard was supposed to let the player input their name and then display their score with the name on the leaderboard. For now the structure is there. After a round, a window opens where it asks the player to input their name for the leaderboard, but it won’t do anything actually and the score nor the name is stored anywhere.

Screenshots from the game

Main Menu
Options
High Score
Game Play
High Score from Game Play

Thank you for reading about my project!

-Derri the Developer and Sandy the Crested Gecko


Leave a Reply

Your email address will not be published. Required fields are marked *