Improving Text Objects' position


The only issue that iv ever encountered with text objects, is the difficulty in creating them in game, centered in relation to an object.

Iv seen some people asking for something similar, by adding “Points” to text objects, but that could not be done because of limitations.

So heres my idea, if possible…

  • The text object does have one origin point, the one its created from and the one that is snapped to the grid if using one, if this isnt a “Point”, at least its a reference position that GDevelop uses and what im gonna use for my suggestion.

Request #1
Add a field, under object properties, to choose the initial size if the Text Object, sort of like we have for Tiled Sprites.
We can specify that when the text object is created it would have those measurements, for example 640x32. 640 Width / 32 Height.
This alone would be pretty awesome and helpful, but way better combined with the next request.

Request #2
Add a checkbox under object properties, that specifies “Create Text Object from Center Point”.
What this would do, if we cant just have a new “Point”, would be this…

  • We perform the Action “Create Object” “TextObject” at the position of “Player.CenterX() / Player.CenterY()-64”.
  • Object now gets created with the specified Width and Height, in this example 640x32, and then gets shifted forward by half the “Width”, in this case, 320px, essebtially creating the object at “Player.CenterX()+320 / Player.CenterY()-64”

The second request can be done with conditions and actions if we had request #1, but would be nice to have the feature.

Centering text object over other objects would be a breeze, all we would do is “Center Text”, then specify the “Initial Size” and then if implemented either check “Create at Center” or just do it manually, specifing the X and Y taking into account the “Initial Size”.

Any chance this can be added? Would help a bunch!