// -------------------------------------------------------------- // Action Fields // -------------------------------------------------------------- /// <summary> /// Get a tag mask. /// </summary> /// <param name="title">Title for action field.</param> /// <param name="actionParams">Action field parameters.</param> /// <param name="actionField">Action field.</param> /// <param name="titleToLeft">Show the title on the left?</param> public static void BuildField(string title, HeroActionParams actionParams, HeroActionField actionField, bool titleToLeft = false) { // create the fields TagMaskValueData data = CreateFieldData(title, actionField, actionParams.heroObject); //----------------------------------------- // Display this title above the field //----------------------------------------- if (data.title != "" && !titleToLeft) { SimpleLayout.Label(data.title); } SimpleLayout.BeginHorizontal(); if (data.title != "" && titleToLeft) { SimpleLayout.Label(data.title); } //----------------------------------------- // Get the bool list you want to work with. // The bool list is in hero object editor > Variables //----------------------------------------- data.fieldValue = SimpleLayout.TagMaskField(data.fieldValue, 200); //----------------------------------------- // assign values back to hero object fields //----------------------------------------- actionField.ints[0] = data.fieldValue; //----------------------------------------- // Visual stuff //----------------------------------------- SimpleLayout.Space(); SimpleLayout.EndHorizontal(); }