Exemple #1
0
    public static void StripForPreview()
    {
        //Show existing window instance. If one doesn't exist, make one.
        GameObject root = BZWToolsWindow.GetRoot();

        DeleteBZWComponentsOnChildren(root);
    }
Exemple #2
0
    public static GameObject AddMapObject <T>(GameObject gb, BZFlag.Map.Elements.BasicObject obj) where T : BZWBasicObject
    {
        AddToRoot(BZWToolsWindow.GetRoot(), gb);
        T      bzw  = gb.AddComponent <T>();
        string name = obj.Name;

        if (name == string.Empty)
        {
            name = obj.ObjectType + "_" + obj.GUID;
        }
        gb.name = name;

        bzw.Setup(obj);

        return(gb);
    }
Exemple #3
0
 public static GameObject NewMapObject(GameObject obj)
 {
     AddToRoot(BZWToolsWindow.GetRoot(), obj);
     return(obj);
 }