Runtime

The Extended Images Runtime refers to the __ExtendedImages script that gives you access to the gml functions and custom sprite data.

Drag and drop the Extended Images gml from Windows -> Prefab Library to your Asset Browser

sprite_get_data

sprite_get_data(sprite_index)

Gets the custom data from the data table in "Sprite Data" section of sprite editor.

var _spr_data = sprite_get_data(spr_player);
shadow_sprite = _spr_data.shadow_sprite;

sprite_get_data_point

sprite_get_data_point(sprite_index, image_index, point_name)

Returns the PointFrame for a point at a given sprite_index, image_index, point_name pair. The data contained in the struct will depend on what point type you used. Watch out for crashes on accessing invalid properties on the wrong type.


var _hat = sprite_get_data_point(sprite_index, image_index, "hat");

draw_self();
draw_sprite(_hat.sprite, 0, x + _hat.x, y + _hat.y);

var _left_hand = sprite_get_data_point(sprite_index, image_index, "left_hand");
draw_circle(x + _left_hand.x, y + _left_hand.y, 2, false);

PointFrame

PointFrame
{
  type,
  x,
  y,
  // your custom data table
  data
  // these props will only exist depending on the type
  // you selected in editor
  sprite,
  image_angle,
  image_scalex,
  image_scaley,
  image_alpha,
  image_color,
  radius,
  box_width,
  box_height,
}