public bool SetParameter(int eventID, int parameterIndex, float value, GameObject parentGameObject = null) { if (_forceQueueAllEvents) { parameter = new ParameterData(); } parameter._index = parameterIndex; parameter._value = value; return(PostEvent(eventID, EventAction.SetParameter, parameter, parentGameObject)); }
public bool SetParameter(int eventID, string parameterName, float value, GameObject parentGameObject = null) { if (_forceQueueAllEvents) { parameter = new ParameterData(); } parameter._parameter = parameterName.GetHashCode(); parameter._index = -1; parameter._value = value; return(PostEvent(eventID, EventAction.SetParameter, parameter, parentGameObject)); }
public EventStatus SetParameter(Event zEvent) { EventStatus result = EventStatus.Failed_Uknown; if (_parameters == null) { return(result); } for (int i = 0; i < _parameters.Length; i++) { RTPParameterToProperty rTPParameterToProperty = _parameters[i]; ParameterData parameterData = (ParameterData)zEvent._parameter; if (rTPParameterToProperty._parameter != null && ((parameterData._index >= 0) ? (i == parameterData._index) : (rTPParameterToProperty._parameter._ID == parameterData._parameter))) { rTPParameterToProperty._parameter.SetValue(parameterData._value); result = EventStatus.Handled; } } return(result); }