Skip to content

Image Swapping

Andrew Hernandez edited this page Jul 1, 2026 · 2 revisions

System Summary

Descriptive summary of what the system is and what it does.

A script that handles the image related aspects of the asset manager.


Connected Systems

List of connecting/parent/subsystems.

Connecting Systems:


Bugs

List of known bugs. Be descriptive but keep it brief!

  • None

Feature List / Breakdown of Features

List of features and descriptions within system.

Image Loading:

  • Users can load an image from their file system
  • This loaded image gets copied to their project's file system
  • This loaded image gets added to the tileset in place of whichever tile it is replacing

Image Previewing:

  • A user can preview what any tile or non-animated entity looks like, whether using the default or their custom asset.

Important Variables

Name the most important variables, their type, and what their purpose is

  • mainTileMap: TileMapLayer = Reference to the main tile map for the purposes of switching the tile textures.
  • tileTypes : Array[String] = Array of all of the tile types in the project. There is also one for props.

Important Functions

Name of the most important functions, their parameters, and what they do.

  • func refresh_images() -> void: Refreshes all of the images in the projects.
  • func change_tile_texture(sourceID : int, newImage : Image, tileMap : TileMapLayer) -> void: Changes the texture of the tile at sourceID to a different texture.
  • func replace_image(newImagePath : String) -> void: Replaces the currently selected image with the image chosen by a user.
  • func reset_image() -> void: Resets the currently selected image back to its default.

Future Work / Risks

List and description of upcoming work/risks.

Future Work:

  1. Making the goal image swappable

Risks:

  • N/A

Miscellaneous Notes

A place for miscellaneous notes pertaining to this system.

  • N/A

Clone this wiki locally