コード例 #1
0
        public bool Equals(DestinyItemTalentGridBlockDefinition input)
        {
            if (input == null)
            {
                return(false);
            }

            return
                ((
                     TalentGridHash == input.TalentGridHash ||
                     (TalentGridHash.Equals(input.TalentGridHash))
                     ) &&
                 (
                     ItemDetailString == input.ItemDetailString ||
                     (ItemDetailString != null && ItemDetailString.Equals(input.ItemDetailString))
                 ) &&
                 (
                     BuildName == input.BuildName ||
                     (BuildName != null && BuildName.Equals(input.BuildName))
                 ) &&
                 (
                     HudDamageType == input.HudDamageType ||
                     (HudDamageType != null && HudDamageType.Equals(input.HudDamageType))
                 ) &&
                 (
                     HudIcon == input.HudIcon ||
                     (HudIcon != null && HudIcon.Equals(input.HudIcon))
                 ));
        }
コード例 #2
0
        public string GetPlatformPath(UnrealTargetRole Type, UnrealTargetPlatform Platform)
        {
            if (Type.UsesEditor())
            {
                return(UnrealPath.FullName);
            }

            string BuildPath = BuildPaths.ElementAt(0);

            if (string.IsNullOrEmpty(BuildPath))
            {
                return(null);
            }

            string PlatformPath = Path.Combine(BuildPath, UnrealHelpers.GetPlatformName(Platform, Type, UsesSharedBuildType));

            // On some builds we stage the actual loose files into a "Staged" folder
            if (Directory.Exists(PlatformPath) && Directory.Exists(Path.Combine(PlatformPath, "staged")))
            {
                PlatformPath = Path.Combine(PlatformPath, "Staged");
            }

            // Urgh - build share uses a different style...
            if (Platform == UnrealTargetPlatform.Android && BuildName.Equals("Local", StringComparison.OrdinalIgnoreCase) == false)
            {
                PlatformPath = PlatformPath.Replace("Android_ETC2Client", "Android\\FullPackages");
            }

            return(PlatformPath);
        }
コード例 #3
0
    private static void Build(BuildName type, string savePath, EditorBuildSettingsScene[] scenes = null, string windowBuildName = null)
    {
        if (scenes == null)
        {
            scenes = EditorBuildSettings.scenes;
        }

        var scenesStr = scenes.Where(s => s.enabled).Select(s => s.path).ToArray();

        buildName = type;

        //PlayerSettings.displayResolutionDialog = ResolutionDialogSetting.Enabled;

        if (!string.IsNullOrEmpty(savePath))
        {
            BuildOptions opts = BuildOptions.None;
            if (customSettings.showDebug)
            {
                opts = opts | BuildOptions.Development | BuildOptions.AllowDebugging | BuildOptions.ConnectWithProfiler;
            }

            BuildPipeline.BuildPlayer(scenesStr, savePath,
                                      BuildTarget.StandaloneWindows64, opts);
        }
        //buildName = BuildName.PRODUCTION;
    }
コード例 #4
0
    private static void BuildConsole(string savePath)
    {
        EditorBuildSettingsScene[] scenes = new EditorBuildSettingsScene[] {
            new EditorBuildSettingsScene("Assets/Scenes/Loader.unity", true),
            new EditorBuildSettingsScene("Assets/Scenes/Console.unity", true)
        };
        var scenesStr = scenes.Where(s => s.enabled).Select(s => s.path).ToArray();

        buildName = BuildName.CONSOLE;

        // PlayerSettings.displayResolutionDialog = ResolutionDialogSetting.Enabled;
        PlayerSettings.SetAspectRatio(AspectRatio.AspectOthers, true);
        PlayerSettings.d3d9FullscreenMode  = D3D9FullscreenMode.FullscreenWindow;
        PlayerSettings.visibleInBackground = true;

        customSettings.xResolution = 1920;
        customSettings.yResolution = 720;
        customSettings.fullscreen  = true;

        if (!string.IsNullOrEmpty(savePath))
        {
            BuildOptions opts = BuildOptions.ShowBuiltPlayer;
            opts = opts | BuildOptions.Development | BuildOptions.AllowDebugging | BuildOptions.ConnectWithProfiler;

            BuildPipeline.BuildPlayer(scenesStr, savePath,
                                      BuildTarget.StandaloneWindows64, opts);
        }
        buildName = BuildName.CUSTOM;
    }
コード例 #5
0
    private static void Build(BuildName type, EditorBuildSettingsScene[] scenes = null, string windowBuildName = null)
    {
        string fileName = "JLR_" + type.ToString() + "_" + ShowBuild.GetBuildNumber();

        if (windowBuildName != null)
        {
            fileName += "_" + windowBuildName;
        }

        string savePath = EditorUtility.SaveFilePanel("Save Build", Application.dataPath, fileName, "exe");

        Build(type, savePath, scenes, windowBuildName);
    }
コード例 #6
0
ファイル: frmMain.cs プロジェクト: lzf98/C-Sharp-Demo
        private string PhotoSave(string currentPhotoName)//把照片储存到指定文件夹内并返回相对路径
        {
            //生成16位图片名称
            string photoName = BuildName.BuildPhotoName(currentPhotoName);

            //产生路径
            photoName = ".\\image\\" + txtSNO.Text.Trim() + photoName;
            //储存图片
            Bitmap objBitmap = new Bitmap(pbCurrentPhoto.BackgroundImage);

            objBitmap.Save(photoName, pbCurrentPhoto.BackgroundImage.RawFormat);
            objBitmap.Dispose();

            return(photoName);
        }
コード例 #7
0
 public override int GetHashCode()
 {
     unchecked
     {
         int hashCode = (ProjectKey != null ? ProjectKey.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (ProjectName != null ? ProjectName.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (BuildName != null ? BuildName.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ (PlanKey != null ? PlanKey.GetHashCode() : 0);
         hashCode = (hashCode * 397) ^ Enabled.GetHashCode();
         hashCode = (hashCode * 397) ^ IsBuilding.GetHashCode();
         hashCode = (hashCode * 397) ^ IsActive.GetHashCode();
         hashCode = (hashCode * 397) ^ AverageBuildTimeInSeconds.GetHashCode();
         return(hashCode);
     }
 }
コード例 #8
0
ファイル: DroneInfo.cs プロジェクト: Hendrik410/KKS_Drone
 public override int GetHashCode()
 {
     unchecked
     {
         int hash = 13;
         hash = hash * 7 + (Name == null ? 0 : Name.GetHashCode());
         hash = hash * 7 + (ModelName == null ? 0 : ModelName.GetHashCode());
         hash = hash * 7 + (SerialCode == null ? 0 : SerialCode.GetHashCode());
         hash = hash * 7 + (BuildName == null ? 0 : BuildName.GetHashCode());
         hash = hash * 7 + BuildVersion.GetHashCode();
         hash = hash * 7 + HighestRevision.GetHashCode();
         hash = hash * 7 + ResetReason.GetHashCode();
         hash = hash * 7 + ResetException.GetHashCode();
         hash = hash * 7 + StopReason.GetHashCode();
         return(hash);
     }
 }
コード例 #9
0
    void SetUIData()
    {
        ui.buttonCopy.SetOnclik(CopyData);
        ui.buttonPaste.SetOnclik(PasteData);
        ui.buttonSave.SetOnclik(SaveData);
        ui.buttonClear.SetOnclik(ClearData);
        ui.buttonLocal.SetOnclik(LocalImg);
        ui.ControlButton.SetOnclik(delegate
        {
            if (frame - clickFrame < 10)
            {
                ui.UIPostionReast();
            }
            clickFrame = frame;
        });
        SetPageData();
        for (int i = 0; i < 7; i++)
        {
            int index = i;
            ui.ButtonDataFile[i].SetOnclik(delegate
            {
                SelectData = GetData(index);
                if (SelectData != null)
                {
                    AddChangeBuild(SelectData);
                }
                isShowImg    = true;
                isLookLocal  = false;
                isAreaSelect = false;
                AreaTrue();
                ui.ChangeRecipe.SetActive(true);
            });
        }
        ui.ButtonDataUp.SetOnclik(delegate
        {
            if (atPage > 0)
            {
                atPage--;
                PageTo();
            }
        });
        ui.ButtonDataDown.SetOnclik(delegate
        {
            if (atPage < 2100000000)
            {
                atPage++;
                PageTo();
            }
        });
        //点击撤销按钮
        ui.buttonZ.SetOnclik(delegate
        {
            if (GameMain.mainPlayer != null && PastIngData != null)
            {
                PastIngData.CancelTask(GameMain.mainPlayer);
                PastIngData.PasteClear();
            }
        });

        ui.SelectBuild.onValueChanged.AddListener(delegate
        {
            var name = ui.SelectBuild.options[ui.SelectBuild.value].text;
            if (BuildName.ContainsKey(name))
            {
                AddChangeRecipe(BuildName[name]);
            }
        });

        ui.ButtonChangeRecipe.SetOnclik(delegate
        {
            var name = ui.SelectBuild.options[ui.SelectBuild.value].text;
            if (BuildName.ContainsKey(name))
            {
                var recipeName = ui.SelectRecipe.options[ui.SelectRecipe.value].text;
                if (RecipeName.ContainsKey(recipeName))
                {
                    int build  = BuildName[name];
                    int recipe = RecipeName[recipeName];
                    if (SelectData != null)
                    {
                        SelectData.ChangeRecipe(build, recipe);
                        info = SelectData.Name + "\n" + "修改配方成功";
                    }
                }
            }
        });

        ui.ButtonOpneFile.SetOnclik(delegate
        {
            string path = System.Environment.CurrentDirectory + "\\BepInEx\\config\\PlanetFactoryData\\";
            System.Diagnostics.Process.Start(path);
        });

        ui.ButtonReLoadFile.SetOnclik(delegate
        {
            readFile();
            SelectData = null;
            atPage     = 0;
            PageTo();
        });
    }