Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


TrySetDefaultValue<T>(T)

Sets the default value of the variable.
Read time 1 minuteLast updated 6 days ago

Definition

bool TrySetDefaultValue<T>(T value)

Parameters

value

T
The default value to set.

Returns

Type

Description

bool
true
if the default value was successfully set; otherwise,
false
.

Remarks

The default value must be of a type compatible with the variable's IVariable.DataType.