【发布时间】:2019-09-11 12:14:47
【问题描述】:
global variable name 'game_width' index (100009) not set before reading it.
at gml_Object_objTextbox_Create_0 (line 16) port_x = (global.game_width
- box_width - port_width) * 0.5
我在游戏中创建了 global.game_height 和 width,但它不起作用。我该怎么办?
【问题讨论】:
-
看起来
objtextbox比game对象更早创建,这样它在初始化之前就找不到global.game_width。但不确定如何改变它,因为您运行它的时间已经晚于game对象。 -
非常感谢,现在我知道我有什么问题并重写它并且它有效
-
看起来我现在已经理解了这个问题,并决定让我的评论成为答案。 :)
标签: dialog game-maker-studio-2