Vincent Taylor

Today I am giving the player the ability to jump once while airborne, a common stable of many platformers.

Today’s Objective: Extend on the Player Controller to add the ability to double jump (jump from ground, then jump again once while in mid-air).

The Code:

In the PlayerController component, I add 2 new variables which will control the additional jumps:

Today I’m creating a custom player controller which will handle movement, gravity and jumping.

Today’s Objective: Create a custom character controller to handle movement, gravity and jumping.

The Code:

In a new script I’ve called “PlayerController”, I create the movement variables which will control how the player can move:

Today I am creating a camera controller to follow the player, including offsets, dead-zones, and movement smoothing.

Today’s Objective: Create a good quality yet simple camera controller to keep the player in frame regardless of speed, while moving smoothly.

The Code:

I create a new script called “CameraController”, and create variables to manage the deadzone, smoothing, and move speed:

LINQ (Language-Integrated Query) is a set of integrated C# capabilities which allow queries against data.

Today’s Objective: Demonstrate the Min and Max methods of LINQ to get the minimum and maximum numerical values from a data collection.

The Min/Max Methods:

Simple C# LINQ methods used to identify the lowest and highest numerical values in a data collection.

LINQ (Language-Integrated Query) is a set of integrated C# capabilities which allow queries against data.

Today’s Objective: Look at the LINQ Skip method, and its uses in game development.

The LINQ Skip Method:

A straightforward method, the Skip method simply creates a new collection which is a duplicate of the original, except it skips the specified number of entries from the beginning.

Vincent Taylor

Vincent Taylor

Unity game developer / C# Programmer / Gamer. Australian (Tasmanian) indie games developer since 8yo (18 years). Currently looking for games industry employment