This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// extracts all icons in file path_to_icons with a cycle number equal to or greater than icon_index | |
// and appends them, in order, to the map icon .bam file associated with the specified worldmap, | |
// converting the palette of the new icons to that of the existing map icon .bam if necessary | |
DEFINE_ACTION_FUNCTION ~ADD_MAP_ICONS~ | |
INT_VAR icon_index = 0 // sequence (cycle) number of your first icon in your .bam, indexed from 0 | |
STR_VAR path_to_icons = ~~ // full path to the .bam file containing your icons, e.g. ~mymod/bam/mapicons.bam~ | |
worldmap = ~worldmap~ // which .wmp file should these icons be associated with, e.g. ~worldm25~ | |
RET icons_added // how many icons were successfully added. if this is 0, you have a problem | |
new_icon_index // sequence number of your first icon in the new .bam - use this when you patch the worldmap |