コード例 #1
0
 private void RespondToMessage(NewPrefabCategoryWasActivatedMessage message)
 {
     if (Inspector.Get().ActiveInspectorGUIIdentifier == InspectorGUIIdentifier.ObjectSnapping ||
         Inspector.Get().ActiveInspectorGUIIdentifier == InspectorGUIIdentifier.ObjectPlacement)
     {
         DestroyIfExists();
         CreateFromActivePrefabIfNotExists();
     }
 }
コード例 #2
0
        public void SetActivePrefabCategory(PrefabCategory newActivePrefabCategory)
        {
            if (newActivePrefabCategory == null || !ContainsPrefabCategory(newActivePrefabCategory))
            {
                return;
            }

            _prefabCategories.MarkEntity(newActivePrefabCategory);
            NewPrefabCategoryWasActivatedMessage.SendToInterestedListeners(newActivePrefabCategory);
        }
コード例 #3
0
 private void RespondToMessage(NewPrefabCategoryWasActivatedMessage message)
 {
     Repaint();
 }
コード例 #4
0
        public static void SendToInterestedListeners(PrefabCategory newActivePrefabCategory)
        {
            var message = new NewPrefabCategoryWasActivatedMessage(newActivePrefabCategory);

            MessageListenerDatabase.Instance.SendMessageToInterestedListeners(message);
        }