Exemplo n.º 1
0
        public void reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            settingsVersion = globals.SETTINGS_VER;

            onlyEnableInGodmaster    = false;
            comboAffectsPlayerDamage = true;
            comboLossOnHit           = true;

            comboDrainRate = 1.0f;
            damageModifier = 0.4f;

            comboIncrementHits     = 8;
            tenXcomboIncrementHits = 35;

            doNotModifyAnyStringValues = globals.DO_NOT_MODIFY;
            string unset = char.ToString((char)globals.gm1_bestclear.None) +
                           char.ToString((char)globals.gm1_numbindings.None);

            unset     = char.ToString(cheat_detect.checksumString(unset)) + unset;
            soulless1 = unset;
            soulless2 = unset;
            soulless3 = unset;
            soulless4 = unset;
            soulless5 = unset;
        }
Exemplo n.º 2
0
 public void Reset()
 {
     BoolValues.Clear();
     StringValues.Clear();
     IntValues.Clear();
     FloatValues.Clear();
 }
        public void Reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            infiniteGrimmIntegration = true;
            ghostBalls = true;

            maxAttackSpeedMult = 2.5f;
            maxRangeMult       = 2.0f;
            maxBallMoveSpeed   = 1.5f;
            maxBallSize        = 2.0f;

            maxDamage   = 1000;
            notchesCost = 2;
            maxSoulAdd  = 200;

            volumeMultiplier = 0.6f;

            colorAlpha = 1.0f;
            colorBlue  = 1.0f;
            colorRed   = 1.0f;
            colorGreen = 1.0f;

            SettingsVersion = VersionInfo.SettingsVer;
        }
Exemplo n.º 4
0
 static void ClearWithoutEvent()
 {
     IntValues.Clear();
     FloatValues.Clear();
     StringValues.Clear();
     Vector3Values.Clear();
     ColorValues.Clear();
 }
Exemplo n.º 5
0
        public void reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            settingsVersion = version_info.SETTINGS_VER;
        }
        public void Reset()
        {
            BoolValues.Clear();
            StringValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();

            //foreach(string s in EnemyRandomizerDatabase.enemyTypeNames )
            //{
            //    StringValues.Add( s, s );
            //    BoolValues.Add( s, true );
            //}
        }
Exemplo n.º 7
0
        public void reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            soulDreamFails  = 0;
            falseDreamFails = 0;
            kinDreamFails   = 0;

            soulDreamLevel  = 1;
            falseDreamLevel = 1;
            kinDreamLevel   = 1;

            settingsVersion = version_info.SAVE_VER;
        }
Exemplo n.º 8
0
        public void Reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            //infiniteGrimmIntegration = true;
            // just kidding...


            // floor color in json. defaults to invisible and black.
            rainbowFloor = false;
            // update every x frames
            rainbowUpdateDelay = 6;
            floorColorRed      = 0.0f;
            floorColorGreen    = 0.0f;
            floorColorBlue     = 0.0f;
            floorColorAlpha    = 0.0f;

            SettingsVersion = VersionInfo.SettingsVer;
        }
Exemplo n.º 9
0
        public bool Load(string fullPath)
        {
            if (!File.Exists(fullPath))
            {
                return(false);
            }

            StringValues.Clear();
            ListValues.Clear();
            IsConfigLoaded = false;

            // YML Parser
            try
            {
                bool          isNextLineList = false;
                string        listName       = "";
                List <string> currentList    = new List <string>();
                string[]      configLines    = File.ReadAllLines(fullPath);
                for (int i = 0; i < configLines.Length; i++)
                {
                    string line = configLines[i];
                    // even if in the middle of a list, still allow empty spaces
                    if (line == string.Empty || line.TrimStart()[0] == '#')
                    {
                        continue;
                    }

                    // parse lists. cannot parse lists within a list... not yet atleast ;)
                    if (isNextLineList)
                    {
                        string trimmedListItemStart = line.TrimStart();
                        if (trimmedListItemStart[0] == '-')
                        {
                            string listItem = trimmedListItemStart.After("-").TrimStart().TrimEnd();
                            currentList.Add(listItem);

                            // last line
                            if ((i + 1) == configLines.Length)
                            {
                                if (isNextLineList)
                                {
                                    isNextLineList = false;
                                    ListValues.Add(listName, new List <string>(currentList));
                                    listName = "";
                                    currentList.Clear();
                                    break;
                                }
                            }

                            continue;
                        }
                        else
                        {
                            ListValues.Add(listName, new List <string>(currentList));
                            listName = "";
                            currentList.Clear();
                            isNextLineList = false;
                        }
                    }

                    // parse fields. "string" and "bool" pairs are treaded the same when loading and saving
                    // tho they can be parsed to "true" or "false" as a bool later on... see TryGetBoolean
                    string trimmedStart = line.TrimStart();
                    string trimmedEnd   = line.TrimEnd();
                    string fieldName    = trimmedStart.Before(":");
                    string fieldValue   = trimmedEnd.After(":").TrimStart();
                    if (fieldName.IsEmpty() || fieldName[0] == ':')
                    {
                        continue;
                    }

                    // this is the only thing that can tell if looking for a field/value
                    // or a field/list. fieldValue will always be empty unless you put a
                    // value after the colon. if you put something after the colon then
                    // add the - listValues... idek what could happen but it could break
                    if (fieldValue.IsEmpty())
                    {
                        isNextLineList = true;
                        listName       = fieldName;
                    }
                    else
                    {
                        StringValues.Add(fieldName, fieldValue);
                    }
                }

                ConfigPath     = fullPath;
                IsConfigLoaded = true;
                return(true);
            }
            catch
            {
                StringValues.Clear();
                ListValues.Clear();
                IsConfigLoaded = false;
                return(false);
            }
        }
Exemplo n.º 10
0
        internal void Write(FileWriter writer)
        {
            _savedParamObjects.Clear();
            _savedParamLists.Clear();
            DataValues.Clear();
            StringValues.Clear();
            ObjListOffsets.Clear();
            ListOffsets.Clear();

            writer.ByteOrder = Syroot.BinaryData.ByteOrder.LittleEndian;

            writer.Write(Encoding.ASCII.GetBytes("AAMP"));
            writer.Write(Version);
            writer.Write(Endianness);

            long sizeOffset = writer.Position;

            writer.Write(0); //Write the file size later
            writer.Write(ParameterIOVersion);

            uint DataSectionSize   = 0;
            uint StringSectionSize = 0;
            uint UnkUintCount      = 0;

            writer.Write(AlignUp(ParameterIOType.Length + 1, 4));
            long totalCountOffset = writer.Position;

            writer.Write(TotalListCount);
            writer.Write(TotalObjCount);
            writer.Write(TotalParamCount);
            writer.Write(DataSectionSize);
            writer.Write(StringSectionSize);
            writer.Write(UnkUintCount);
            writer.Write(ParameterIOType, Syroot.BinaryData.BinaryStringFormat.ZeroTerminated);
            writer.Align(4);

            //Write the lists
            WriteList(writer, RootNode);

            //Save the data and offsets for lists
            for (int index = 0; index < _savedParamLists.Count; index++)
            {
                WriteListData(writer, _savedParamLists[index], ListOffsets[index]);
            }

            //Save objects from lists
            for (int index = 0; index < _savedParamLists.Count; index++)
            {
                ListOffsets[index][1].WriteOffsetU16(writer, (uint)writer.Position);
                foreach (var obj in _savedParamLists[index].paramObjects)
                {
                    WriteObject(writer, obj);
                }
            }

            while (_savedParamObjects.Count != 0)
            {
                WriteObjectData(writer, PopAt(_savedParamObjects, 0));
            }

            uint DataStart = (uint)writer.Position;

            foreach (var entry in DataValues)
            {
                foreach (var offset in entry.Value)
                {
                    if (IsBuffer(((ParamEntry)offset.data).ParamType))
                    {
                        writer.Write(0); //Save offset after the size of buffer
                        offset.WriteOffsetU24(writer, (uint)writer.Position, (ParamEntry)offset.data);
                        writer.Seek(-4, SeekOrigin.Current);
                    }
                    else
                    {
                        offset.WriteOffsetU24(writer, (uint)writer.Position, (ParamEntry)offset.data);
                    }
                }

                writer.Write(entry.Key);
                writer.Align(4);
            }

            uint DataEnd         = (uint)writer.Position;
            uint StringDataStart = (uint)writer.Position;

            int stringCount = 0;

            foreach (var entry in StringValues)
            {
                foreach (var offset in entry.Value)
                {
                    offset.WriteOffsetU24(writer, (uint)writer.Position, (ParamEntry)offset.data);
                    stringCount++;
                }

                writer.Write(entry.Key);

                do
                {
                    writer.Write((byte)0);
                }while (writer.Position % 4 != 0);
            }
            uint StringDataEnd = (uint)writer.Position;

            //Write data size
            writer.Seek(totalCountOffset, System.IO.SeekOrigin.Begin);

            writer.Write(TotalListCount);
            writer.Write(TotalObjCount);
            writer.Write(TotalParamCount);
            writer.Write(DataEnd - DataStart);
            writer.Write(StringDataEnd - StringDataStart);

            //Write end of file
            writer.Seek(sizeOffset, System.IO.SeekOrigin.Begin);
            uint FileSize = (uint)writer.BaseStream.Length;

            writer.Write(FileSize);

            writer.Close();
            writer.Dispose();
        }
Exemplo n.º 11
0
        public void reset()
        {
            BoolValues.Clear();
            IntValues.Clear();
            FloatValues.Clear();
            StringValues.Clear();

            useGreymothDashWhenBlackmothMissing = true;

            overrideBlackmothNailDamage = true;
            overrideBlackmothLore       = true;
            overrideBlackmothCloak      = true;

            handicapAllNonFireAttacks = false;

            nailmasterGloryCost           = 3;
            fireballSoulAddOnHit          = 11;
            fireballDamageBase            = 8;
            fireballDamagePerNailLvl      = 3;
            fireballMagmaDamageBase       = 3;
            fireballMagmaDamagePerNailLvl = 2;
            laserDamageBase           = 15;
            laserDamagePerNailLvl     = 3;
            pillarDamageBase          = 10;
            pillarDamagePerNailLvl    = 6;
            pillarSecondaryDamageBase = 5;
            pillarSecondaryAttacks    = 4;
            trailDamageBase           = 5;
            trailDamagePerNailLvl     = 8;

            // not actually implemented
            //trailSecondaryDamageBase = 2;
            //trailSecondaryDamagePerNailLvl = 1;

            // Causes lasers to only fire when damage taken
            lasersWhenShieldBlocksAllDmg = false;

            useEnglishLoreWhenLanguageMissing        = false;
            useEnglishWarningInfoWhenLanguageMissing = true;

            applyBindingsToRedwingAttacks = true;

            applyCharmBindingToGreymoth      = true;
            applyHealthBindingToShield       = true;
            applyNailBindingToRedwingAttacks = true;
            applySoulBindingToNapalm         = true;

            redwingFirstLaunch = true;



            fireballCooldownBase = 7f;
            laserCooldownBase    = 10f;
            shieldCooldownBase   = 30f;
            shieldCooldownReductionPerNailHit = 0.5f;

            napalmDamageMultiplier = 0.6f;
            napalmDamageExponent   = 0.7f;

            settingsVersion = version_info.SETTINGS_VER;
        }