Giter VIP home page Giter VIP logo

unity-dev-log's Introduction

Unity 2D Dev Log and Guides

Overview

This repo will serve as a way to document and share solutions I've found while working on a top-down RPG project in Unity.

Do note that this series of guides is a constant work in progress, so if some componants are incomplete, know they will be filled in relatively soon!

View the most recent Dev Log Here: Dev Log 1: The Two Month Mark

This repo will contain a number of loose guides that broadly cover a number of objectives, such as how to simulate Z height in a 2D game, how to parse JSON objects as dialoge, and using prefabs for efficient workflow. These are not meant to be full comprehensive guides and instead highlight a use I have personally found for them.

It is recommended that you have at least a basic understanding of code fundementals, familiarity with the C# script (Unity's primary coding language) and a fairly decent grasp on navigating the Unity Scene Editor. Likewise it is recommended to have a existing basic Unity project. This tutorial from Brackeys is a good starting point, but no specific tutorial will be built off of in these guides.

Finally, assets referenced in the guides may be made availible in the accomponying resources folder, and will be hyperlinked for reference.

What I mean by this is something along the lines of the Mario and Luigi series of RPG's where you traverse a 2D world in a top down view and stil have some form of simulated height. These guides will go over the general theory of what a platform is in terms of a game engine, and how we can apply that logic to a series of scripts that both control what collisions effect the player at a specified Z height, and sell the idea that we're truly moving in a 3D space by manipulating our player object.

Guides in Top Down 3D Collision in 2D:

Despite Unity's fairly workable sprite systems, something that will always be frustratingly impersice is the baked in method of sorting single sprites tilemap chunks based on a loosely defined pivot point. With a script that's easy to both write and integrate, we can greatly improve the consistancy of our sprite organization.

Guides in Script Controlled Sprite Sorting:

For the purpose of a Unity dialogue system, you might need to store more data than just the to-be-rendered text. For instance, my project will have a number of text box shapes appropriate to the length of dialogue. Additionally, it's helpful to store animation data for the involved characters alongside the needed text. Therefor storing text in a JSON is a very efficient and readable way to store large amounts of dialogue, and with a few clever work arounds it's a surprisingly flexible method.

Guides in JSON Dialogue System:

When transitioning between scenes in Unity, it wouldn't make sense to constantly despawn and respawn elements like the player character and HUD. Thanks in large part to the DontDestoryOnLoad method, persistant data across scenes is fairly simple to implement. Alongside a Game Manager object to hold methods for RPG battles, player state changes, and a HUD, you can truly begin to evolve from a tech demo to a crafted game world.

Guides in Game Manager:

unity-dev-log's People

Contributors

tannerkothlow avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.