Beispiel #1
0
        public void set(String key, Type t, System.Object value)
        {
            StatemapField field;

            field =
                definitions
                .Where(d => d.name == key)
                .FirstOrDefault();

            if (field == null)
            {
                field      = new StatemapField();
                field.name = key;
                definitions.Add(field);
            }

            field.set(t, value);
        }
Beispiel #2
0
        public void set(Type type, System.Object value)
        {
            IdentifiedGameObject identified;

            this.type  = type;
            this.value = value;

            if (type == typeof(GameObject) || type == typeof(IdentifiedGameObject))
            {
                this.type = typeof(IdentifiedGameObject);

                identified = (IdentifiedGameObject)value;

                if (identified != null && identified.gameObject != null)
                {
                    identified = StatemapField.ensureGUID(identified.gameObject);
                }

                this.value = identified;
            }
        }