Skip to content

Commit 000a4ca

Browse files
committed
Fix an error message
1 parent 492b85d commit 000a4ca

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

json_config_file/json_properties/json_property.gd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ const MESSAGE_ARRAY_BIGGER_THAN_MAX = "The array size (%d) is bigger than the ma
112112
const MESSAGE_ARRAY_TWO_ELEMENTS_ARE_EQUAL = "The array contains two elements that are equal: [%d] and [%d]"
113113
const MESSAGE_COLOR_WRONG_SIZE = "The color is %d element(s) long, when it should be 3 to 4"
114114
const MESSAGE_COLOR_WRONG_TYPE = "Wrong type: expected 'integer' in the range [0, 255]"
115-
const MESSAGE_COLOR_OUT_OF_RANGE = "Element out of the range [0, 255]"
115+
const MESSAGE_COLOR_OUT_OF_RANGE = "%d is out of the range [0, 255]"
116116
const MESSAGE_OBJECT_MISSING_PROPERTY = "The property '%s' has not been specified"
117117
const MESSAGE_OBJECT_NON_VALID_PROPERTY = "The property '%s' is not a valid one"
118118
const MESSAGE_OBJECT_ONE_IS_REQUIRED = "One of this properties needs to be specified: %s"
@@ -184,7 +184,7 @@ static func _error_as_text(error: Dictionary) -> String:
184184
Errors.COLOR_WRONG_TYPE:
185185
error_as_text = MESSAGE_COLOR_WRONG_TYPE
186186
Errors.COLOR_OUT_OF_RANGE:
187-
error_as_text = MESSAGE_COLOR_OUT_OF_RANGE
187+
error_as_text = MESSAGE_COLOR_OUT_OF_RANGE % error.value
188188
Errors.OBJECT_MISSING_PROPERTY:
189189
error_as_text = MESSAGE_OBJECT_MISSING_PROPERTY % error.property
190190
Errors.OBJECT_NON_VALID_PROPERTY:

0 commit comments

Comments
 (0)