Skip to content

Game.UI.Widgets.Int4InputField

Assembly:
Assembly-CSharp (may vary by build; typically the game's runtime assembly)

Namespace:
Game.UI.Widgets

Type:
class

Base:
IntField

Summary:
A concrete UI input field type that specializes the generic IntField for Unity.Mathematics.int4 (a 4-component integer vector). The class itself contains no additional members — it exists to provide a non-generic, concrete type usable by UI systems, serializers and the Unity editor/UI builder that require a concrete class reference.

This control is intended to be used wherever the mod or game UI needs to display or edit a 4-component integer vector (int4). Behavior (appearance, validation, events) is provided by the generic IntField base class.


Fields

  • (none declared in this class)
    This class does not declare any private or public fields itself. All internal state and fields are inherited from IntField (the generic base).

Properties

  • (none declared in this class)
    No additional properties are defined here. Use the properties provided by the IntField base class (for example, typical implementations expose a Value/ValueChanged or similar API — consult IntField documentation or source).

Constructors

  • (default constructor, inherited)
    No constructors are explicitly declared; the default parameterless constructor from the base/object applies.

Methods

  • (none declared in this class)
    All runtime behavior and methods come from the generic base class IntField.

Usage Example

using Unity.Mathematics;
using Game.UI.Widgets;

// Example usage in your UI code.
// Exact API names for setting/getting value or subscribing to change events depend on IntField<T> implementation.
var int4Field = new Int4InputField();

// Set initial value (replace 'Value' with the actual property/method name from IntField<T> if different)
int4Field.Value = new int4(1, 2, 3, 4);

// Subscribe to value changes (API name may differ — adapt to IntField<T>'s event/callback)
int4Field.OnValueChanged += (int4 newValue) =>
{
    UnityEngine.Debug.Log($"int4 changed: {newValue.x}, {newValue.y}, {newValue.z}, {newValue.w}");
};

Notes: - Because this class is just a concrete specialization, refer to the IntField base class for styling, validation, event names, and lifecycle (e.g., creation, disposal, Unity callbacks). - Ensure you have a using Unity.Mathematics; directive to work with int4.