Release notes and general information about GameMaker releases.
Download Links: Windows - macOS - Ubuntu Beta
layer_text_get_id(layer_id,text_element_name)
- This function can be used to retrieve the unique ID value of a text element on a layer. You supply the layer ID (which you get when you create the layer using layer_create() or when you use the layer name along with layer_get_id()) and the name of the text element as defined in the Room Editor. The function will return the ID value associated with that text element on the layer.layer_text_exists(layer_id,text_element_id)
- You can use this function to check and see if a text element exists on any given layer. You supply the layer ID (which you get when you create the layer using layer_create()) or the layer name (as a string - this will have a performance impact) and the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()) and the function will return either true if the element exists, or false if it does not.layer_text_create(layer_id,x,y,font,text)
- With this function you can create a new text element on the specified layer. You supply the layer ID (which you get when you create the layer using layer_create() or when you use the layer name along with layer_get_id()), a position within the room, a font reference (which would be the name of the font as shown in the Asset Browser), and the text to be displayed and it will be added to the layer. The function returns the unique ID value for the element, which can then be used in further layer functions for text elements.layer_text_destroy(text_element_id)
- This function will destroy the given text element. You supply the text ID (which you get when you create the text using layer_text_create() or when you use the layer ID along with layer_get_text_id()) and this will remove it. Note that this does not remove the layer, only the text element from it, and if the text element is one that has been added in the room editor, then the next time you leave the room and then return, the text element will be recreated again. However if the room is persistent, the text element will be removed unless room persistence is switched off again.layer_text_x(text_element_id,x)
- This function controls the position along the x-axis of the room of the text element on the layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the x value to use (based on the room coordinates).layer_text_y(text_element_id,y)
- This function controls the position along the y-axis of the room of the text element on the layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the y value to use (based on the room coordinates).layer_text_angle(text_element_id,angle)
- Using this function you can change the angle for the given text element on a layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the angle value, from 0 to 359 anti-clockwise, where 0 is to the right, 90 is to the top, 180 is to the left and 270 is to the bottom. If you set a value greater than 360 this will be looped to bring it within the 0 - 359 range.layer_text_xscale(text_element_id,xscale)
- Using this function you can change whether the given text element on a layer should be scaled along the x axis or not. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the scale value. A scale of 1 indicates no scaling (1:1), smaller values will scale down (0.5, for example, will half the width of the text element), larger values will scale up, and negative values will flip the text element and scale it unless the value used is exactly -1 (in which case the text element used is just flipped right-to-left about its origin position with no scaling).layer_text_yscale(text_element_id,yscale)
- Using this function you can change whether the given text element on a layer should be scaled along the y axis or not. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the scale value. A scale of 1 indicates no scaling (1:1), smaller values will scale down (0.5, for example, will half the height of the text element), larger values will scale up, and negative values will flip the text element and scale it unless the value used is exactly -1 (in which case the text element used is just mirrored top-to-bottom about its origin position with no scaling).layer_text_blend(text_element_id,blend)
- This function controls the colour (or “tinting”) of the text element and the default value is -1 (which represents the constant c_white, which can also be used). Any other value (including internal colour constants like c_red, or c_aqua) will draw the text element with the specified colour. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the colour to use.layer_text_alpha(text_element_id,alpha)
- This function controls the alpha (transparency) of the text element on the asset layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the alpha value to use. Alpha can be between 0 (fully transparent) and 1 (fully opaque) with the default alpha value for the text element being 1. Note that if the layer the text element has been assigned to is not visible - or the element itself has been made invisible - you will not see any difference with this function until the layer or element has been made visible again.layer_text_font(text_element_id,font)
- Using this function you can change the font resource assigned to a given text element on a layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then supply a font resource reference which the text element will be changed to use.layer_text_xorigin(text_element_id,xorigin)
- Using this function you can change the x position of the origin of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the origin value.layer_text_yorigin(text_element_id,yorigin)
- Using this function you can change the y position of the origin of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the origin value.layer_text_text(text_element_id,text)
- Using this function you can change the text string assigned to a given text element on a layer. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then supply a text string which the text element will be changed to use.layer_text_halign(text_element_id,alignment)
- Using this function you can change the horizontal alignment of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the alignment value.layer_text_valign(text_element_id,alignment)
- Using this function you can change the vertical alignment of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the alignment value.layer_text_charspacing(text_element_id,charspacing)
- Using this function you can change the character spacing of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the spacing value.layer_text_linespacing(text_element_id,linespacing)
- Using this function you can change the line spacing of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the spacing value.layer_text_framew(text_element_id,width)
- Using this function you can change the width of the frame of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the frame width value. This only affects rendering when wrapping is enabled.layer_text_frameh(text_element_id,height)
- Using this function you can change the height of the frame of the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set the frame width value. The affects vertical alignment of the text.layer_text_wrap(text_element_id,wrap)
- Using this function you can change whether wrapping is enabled for the given text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and then set true or false for the wrapping value.layer_text_get_x(text_element_id)
- This function can be used to get the x position of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the x position value.layer_text_get_y(text_element_id)
- This function can be used to get the y position of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the y position value.layer_text_get_xscale(text_element_id)
- This function can be used to get the x scale of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the x scale value.layer_text_get_yscale(text_element_id)
- This function can be used to get the y scale of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the y scale value.layer_text_get_angle(text_element_id)
- This function can be used to get the rotation angle of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the rotation angle value.layer_text_get_blend(text_element_id)
- This function can be used to get the blend colour of the text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return real value that represents the colour assigned.layer_text_get_alpha(text_element_id)
- This function can be used to get the alpha value of the text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return a value between 0 (fully transparent) and 1 (fully opaque).layer_text_get_font(text_element_id)
- This function can be used to get the font resource reference of the text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the font resource referenced assigned to the element.layer_text_get_xorigin(text_element_id)
- This function can be used to get the x origin of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the x origin value.layer_text_get_yorigin(text_element_id)
- This function can be used to get the y origin of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the y origin value.layer_text_get_text(text_element_id)
- This function can be used to get the text string of the text element. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the text string displayed by the element.layer_text_get_halign(text_element_id)
- This function can be used to get the horizontal alignment of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the horizontal alignment value.layer_text_get_valign(text_element_id)
- This function can be used to get the vertical alignment of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the vertical alignment value.layer_text_get_charspacing(text_element_id)
- This function can be used to get the character spacing of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the character spacing value.layer_text_get_linespacing(text_element_id)
- This function can be used to get the line spacing of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the line spacing value.layer_text_get_framew(text_element_id)
- This function can be used to get the width of the frame of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the frame width value.layer_text_get_frameh(text_element_id)
- This function can be used to get the height of the frame of the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the frame height value.layer_text_get_wrap(text_element_id)
- This function can be used to get whether wrapping is enabled for the text element in the room. You give the text element ID (which you get when you create a text element using layer_text_create() or when you use the function layer_text_get_id()), and the function will return the wrapping status.buffer_get_surface_depth(buffer,surface,offset)
- With this function you can write information from a surface’s depth buffer to a given buffer. The buffer must have been created previously and should be a 1-byte aligned buffer large enough to store data for the surface you are going to write (if unsure, use a grow buffer or see the example at the bottom of this page).buffer_set_surface_depth(buffer,surface,offset)
- With this function you can write information from a buffer to a depth buffer of a given surface. Both the buffer being read from and the surface being written to must have been created previously, and you can provide an offset into the buffer to start reading from. Note that reading will always start at the beginning of the buffer plus the offset value and not at the current seek position plus the offset value.dbg_text_separator(dbgref)
- Creates a text separator entry (from a variable) within the current debug section, this text can be multiline and is not split into 2 columns but shown in a single column. NOTE: if no section is declared a “Default” section will be created.draw_clear_depth(depth)
- This function can be used to clear the depth buffer of the current render target.draw_clear_ext([col],[alpha],[depth],[stencil])
- This function can be used to clear colour, depth and stencil of the current render target.draw_clear_stencil(stencil)
- This function can be used to clear the stencil buffer of the current render target.gpu_get_sprite_cull()
- With this function you can check to see whether sprite culling is enabled (returns true) or not (returns false). For more information on sprite culling, see the function gpu_set_sprite_culling().gpu_get_stencil_depth_fail()
- This function can be used to retrieve the stencil operation executed when the stencil test passes but the depth test fails.gpu_get_stencil_enable()
- This function can be used to retreive whether the stencil test is currently enabled (returns true) or not (returns false).gpu_get_stencil_fail()
- This function can be used to retrieve the stencil operation executed when the stencil test fails.gpu_get_stencil_func()
- This function can be used to retrieve the current stencil test function.gpu_get_stencil_pass()
- This function can be used to retrieve the stencil operation executed when both stencil and depth test pass.gpu_get_stencil_read_mask()
- This function can be used to retrieve the current stencil test read mask value.gpu_get_stencil_ref()
- This function can be used to retrieve the current stencil test reference value.gpu_get_stencil_write_mask()
- This function can be used to retrieve the current stencil test write mask value.gpu_set_sprite_cull(enable)
- This function will enable or disable sprite culling for your game (by default this is enabled). By switching sprite culling off you can avoid any problems with for example sprites not being drawn when using custom shaders that alter the position the sprite is drawn atgpu_set_stencil_depth_fail(stencil_op)
- This function can be used to set the stencil operation taken when the stencil test passes but the depth test fails.gpu_set_stencil_enable(enable)
- This function can be used to disable or enable the stencil test.gpu_set_stencil_fail(stencil_op)
- This function can be used to set the stencil operation taken when the stencil test fails.gpu_set_stencil_func(cmp_func)
- This function can be used to set the stencil test function.gpu_set_stencil_pass(stencil_op)
- This function can be used to set the stencil operation taken when both the stencil and the depth test pass.gpu_set_stencil_read_mask(read_mask)
- This function can be used to set the stencil test read mask.gpu_set_stencil_ref(ref)
- This function can be used to set the stencil test reference value.gpu_set_stencil_write_mask(write_mask)
- This function can be used to set the stencil test write mask.surface_get_target_depth()
- This function can be used to retrieve the ID of the surface whose depth buffer is set as the current one.surface_get_texture_depth(surface_id)
- This function returns a special pointer for the depth buffer texture of a surface. This value can then be used in other draw functions, particularly in general 3D and some of the 2D primitive functions.surface_has_depth(surface_id)
- This function returns whether given surface has a depth buffer (returns true) or not (returns false). By default all surfaces have a depth buffer unless depth buffers are disabled using function surface_depth_disable().physics_raycast(xStart,yStart,xEnd,yEnd,ids,[all_hits],max_fraction)
- This function checks the physics fixtures of the objects given against the ray specified, it will return an array of structures that will give the hitPointX, hitPointY (the room coordinates of the intersection), normalX, normalY (the normal of the intersection), fraction (the normalised distance down the ray of the intersection)struct_exists_from_hash(struct,hash)
- With this function you can check whether a variable exists within the given struct or not. . The function will return true if a variable with the given hash exists for the struct and false otherwise.struct_remove_from_hash(struct,hash)
- With this function you can remove a variable from a struct. You supply the struct ID to remove the variable from and the hash of the variable to be removed.dbg_slider(dbgref,[minimum],[maximum],[label])
changed to dbg_slider(dbgref,[minimum],[maximum],[label],[step])
dbg_slider_int(dbgref,[minimum],[maximum],[label])
changed to dbg_slider_int(dbgref,[minimum],[maximum],[label],[step])
surface_set_target(surface_id)
changed to surface_set_target(surface_id,[depth_id])
textalign_left
- Indicates that text should be aligned to the left of the frame.textalign_right
- Indicates that text should be aligned to the right of the frame.textalign_center
- Indicates that text should be centred horizontally within the frame.textalign_justify
- Indicates that text should be justified within the frame.textalign_top
- Indicates that text should be aligned to the top of the frame.textalign_bottom
- Indicates that text should be aligned to the bottom of the frame.textalign_middle
- Indicates that text should be centered vertically within the frame.stencilop_keep
-stencilop_zero
-stencilop_replace
-stencilop_incr_wrap
-stencilop_decr_wrap
-stencilop_invert
-stencilop_incr
-stencilop_decr
-ActiveTrack {
/* ___ */ activeTracks : ,
/* ___ */ matrix : ,
/* ___ */ posx : ,
/* ___ */ posy : ,
/* ___ */ scalex : ,
/* ___ */ scaley : ,
/* ___ */ xorigin : ,
/* ___ */ yorigin : ,
/* ___ */ gain : ,
/* ___ */ pitch : ,
/* new */ falloffRef : ,
/* new */ falloffMax : ,
/* new */ falloffFactor : ,
/* ___ */ width : ,
/* ___ */ height : ,
/* ___ */ imageindex : ,
/* ___ */ imagespeed : ,
/* ___ */ colorMultiply : ,
/* ___ */ colourMultiply : ,
/* ___ */ emitterIndex : ,
/* ___ */ track : ,
/* ___ */ parent : ,
/* ___ */ frameSizeX : ,
/* ___ */ frameSizeY : ,
/* ___ */ characterSpacing : ,
/* ___ */ lineSpacing : ,
/* ___ */ paragraphSpacing : ,
/* ___ */ thickness : ,
/* ___ */ coreColor : ,
/* ___ */ coreColour : ,
/* ___ */ glowStart : ,
/* ___ */ glowEnd : ,
/* ___ */ glowColor : ,
/* ___ */ glowColour : ,
/* ___ */ outlineDist : ,
/* ___ */ outlineColor : ,
/* ___ */ outlineColour : ,
/* ___ */ shadowSoftness : ,
/* ___ */ shadowOffsetX : ,
/* ___ */ shadowOffsetY : ,
/* ___ */ shadowColor : ,
/* ___ */ shadowColour : ,
/* ___ */ effectsEnabled : ,
/* ___ */ glowEnabled : ,
/* ___ */ outlineEnabled : ,
/* ___ */ dropShadowEnabled :
}