Giter VIP home page Giter VIP logo

rush-hour's Introduction

Rush Hour

Simple Unity rush hour puzzle game

Development

TODO

Assets

There are several assets that must be installed to work with the project!

  • External/
    • ALINE
    • Message Dispatched (ooti)
  • Plugins/
    • Odin Inspector (Sirenix)

Caveats

Unity Serialization

Unity does not serialize public properties or private attributes by default, which can lead to some interesting/unexpected scenarios. Public attributes will be properly serialized and displayed in the editor.

Public properties can be displayed in the editor but will not be serialized. Instead, use a serialized private property along with a public accessor to both display and serialize the data.

Private fields can be serialized and displayed in the editor with the [SerializeField] attribute. However, without this attribute private fields will not be serialized (stored)! If wanting to serialize a private field but not display it, add both the [SerializeField] and [HideInInspector] attributes.

Message Dispatcher

Due to the way Unity's "Fast Play" mode works, the "Domain Reload" option conflicts with the Message Dispatcher static fields. As Unity Manual on this topic, some additional work is needed in the MessageDispatcher class. Without these changes (including Editor tags!), the DontDestroyOnLoad object used to track events will not be present!

[RuntimeInitializeOnLoadMethod(RuntimeInitializeLoadType.SubsystemRegistration)]
static void Init()
{
    Debug.Log("Message Dispatcher - Init");

    sStub = (new GameObject("MessageDispatcherStub")).AddComponent<MessageDispatcherStub>();
    mMessages = new List<IMessage>();
    mMessageHandlers = new Dictionary<string, Dictionary<string, MessageHandler>>();
    mListenerAdds = new List<MessageListenerDefinition>();
    mListenerRemoves = new List<MessageListenerDefinition>();
}

rush-hour's People

Contributors

kendallroth avatar

Watchers

James Cloos avatar  avatar  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.