Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Error from Copying Episode 1

A topic by D-goCa created Jul 06, 2023 Views: 197 Replies: 2
Viewing posts 1 to 3

I copied the instructions from Episode 1 of the tutorial YT series and encountered the following errors whenever an encounter starts.

"___________________________________________

############################################################################################

ERROR in
action number 1
of Create Event
for object obj_Battle:
Variable <unknown_object>.image_create_depth(100052, -2147483648) not set before reading it.
at gml_Object_obj_Battle_Create_0

############################################################################################

gml_Object_obj_Battle_Create_0 (line -1)
gml_Script_NewEncounter (line -1)
gml_Object_obj_Slime_Collision_obj_Player"

Similarly, in the Feather Messages, I got these four. When rewatching the video, I noticed that the same parts of the code marked for these errors were also marked in the video.
"⚠️: Variable 'enemies' does not exist in object's Variable Definitions.

⚠️: Variable 'creator' does not exist in object's Variable Definitions.

⚠️: Variable 'battleBackground' does not exist in object's Variable Definitions.

❌: The type 'Undefined' appears where the type 'Array' is expected."

Aside from renaming the object names, I'm pretty sure the code and assets are using are exact to the ones Shaun was using. This is my first time using a coding language, however, so I might've missed something.
Developer (1 edit)

There is no such function as "image_create_depth". The function aught to be instance_create_depth.

The feather warnings can be ignored.

I cannot believe I missed that. My bad, and thank you for making the tutorial. The encounter starter works now.