Resource icon

[Reusable] Colorable Signs 3.1

This thread contains content that may be reused, modified, or ported by anyone.

Chaobrother

Member
attachment.php
Colorable Signs is a basic resource wad which turns the majority of arrow midtextures available in patch.kart, textures.kart, and srb2.srb in to colorable paper sprite variants. This wad comes in two variants. K_ColoredArrows and KL_ColoredArrows. K_ColoredArrows is a basic SOC variant which does not modify the game. KL_ColoredArrows is a game modifying script that has the same arrows as the SOC but offers more functionality to manipulate the arrows. Both scripts can be loaded without conflict. K_SignShop is a showcase of the SOC and Lua versions of the script. It replaces MAP01. Operation of the scripts are detailed below.

attachment.php
The SOC signs will take the color of the balloon (thing type 462) closest to them. The ideal usage is to place one balloon somewhere outside of the map so that all arrows share the same color. It is recommended to only add the states, sprites, objects of signs that are actually in your maps to save on file size.
Thing Types
  • Thing type 2222 – Colorable SD2 Sign
  • Thing type 2223 – Colorable Crimson Core Sign
  • Thing type 2224 – Half Scale Colorable SD2 Sign
  • Thing type 2225 – Colorable Kodachrome Void Sign
  • Thing type 2226 – Colorable Basic Arrow
  • Thing type 2227 – Colorable Basic Arrow 2
  • Thing type 2228 – Colorable Double Triangle Arrow
  • Thing type 2229 – Colorable Small Chevron
  • Thing type 2230 – Colorable Sonic Riders Arrow 1
  • Thing type 2231 – Colorable Sonic Riders Arrow 2
  • Thing type 2232 – Colorable Sonic Riders Arrow 3
  • Thing type 2233 – Colorable Peach Gardens Arrow
  • Thing type 2236 – Colorable Honeybee Industries Arrow
  • Thing type 2237 – Colorable Gold Arrow 1
  • Thing type 2238 – Colorable Gold Arrow 2
  • Thing type 2239 – Colorable SD2 Warning
  • Thing type 2240 – Colorable SD2 Boost Warning
  • Thing type 2241 – Colorable SD2 Invincibility Warning
  • Thing type 2242 – Colorable SD2 U-Turn
  • Thing type 2243 – Colorable Animated Double Arrow (Contributed by Charybdizs)
  • Thing type 2244 – Colorable Giant Hand (Contributed by Charybdizs)
Sprite Prefix - SDAR, CCAR, KVAR, BAR1, BAR2, DTA1, SCVA, SRA1, SRA3, PGAR, HIAR, DTA2, CHHD, GDA1, GDA2 ,SDW1, SDW2, SDW3, and SDW4

attachment.php
The Lua signs offer more functionality in a smaller amount of Thing Types at the expense of modifying the game when used. Record Attack will be disabled for levels that use this script unless the map provides its own custom data or is loaded alongside of a map pack that has its own custom data.
The color of any Lua signs is determined by the mapthing’s angle/360. Overflow is accounted for. If the color is invalid, then a warning will show in a console with the position of the violating sign. The violating sign will be a default green color.
The scale of any Lua sign is determined by the object flags. Extra and Ambush quadruples scale, Extra and Special triples scale, Extra doubles scale, Special halves scale and Ambush quarters scale. Special and Amubsh make the scale 1/8 normal.

Thing Type 2234 – Lua Colorable Multi Arrow is the condensed version of 16 of the signs in the SOC version. The parameter value of the arrow determines the type of sign:
  • 0 = SD2 Arrow
  • 1 = Kodachrome Void
  • 2 = Basic Arrow
  • 3 = Basic Arrow without background
  • 4 = Double Triangle Arrow
  • 5 = Small Chevron
  • 6 = Sonic Riders 1
  • 7 = Sonic Riders 3
  • 8 = Peach Gardens
  • 9 = Golden Arrow 1
  • 10 = Golden Arrow 2
  • 11 = Honeybee Industries Arrow
  • 12 = SD2 Warning
  • 13 = SD2 Invincibility
  • 14 = SD2 Shoe
  • 15 = SD2 U-Turn

Thing Type 2235 – Lua Colorable Crimson Core Arrow has the same angle and flag operations as the Multi-Arrow. The parameter value * 2 determines the delay to give the sign before it starts animating.

Thing Type 2245 - Lua Colorable Animated Double Arrow and Thing Type 2246 - Lua Colorable Giant Hand behave like Thing type 2235, but with a different graphic, animation and parameter delay.

Sprite Prefix - SDAR, CCAR, KVAR, BAR1, BAR2, DTA1, SCVA, SRA1, SRA3, PGAR, HIAR, DTA2, CHHD, GDA1, GDA2 ,SDW1, SDW2, SDW3, and SDW4

attachment.php
The signs can mimic their midtexture counterparts if a particular color is used. Imperfect mimicries are noted.
  • SD2 Arrow: Red (balloon angle 23) – It is slightly darker than the normal version.
  • Crimson Core: Raspberry (balloon angle 21)
  • Kodachrome Void: Skunk (balloon angle 5)
  • Basic Arrow: Crimson (balloon angle 24)
  • Basic Arrow Without Background: Ketchup (balloon angle 29) – The middle is slightly darker than the normal version.
  • Double Triangle Arrow: Tea (balloon angle 54)
  • Small Chevron: Raspberry (balloon angle 21)
  • Sonic Riders 1: Blue (balloon angle 84) – Some of the gradient was lost due to skin color limitations.
  • Sonic Riders 2: Green (balloon angle 60)
  • Sonic Riders 3: Green (balloon angle 60)
  • Peach Gardens: Raspberry (balloon angle 21)
  • Honeybee Industries: Bronze (balloon angle 43)
  • Golden Arrow 1: Gold (balloon angle 41)
  • Golden Arrow 2: Red (balloon angle 23)
  • Other SD2 Signs: Red (balloon angle 23)
  • Animated Double Arrow: There is not a default color.
  • Giant Hand: White (balloon angle 1)

attachment.php
The Sign Shop is a testing map which works best with the KL_ColoredArrows and K_ColoredArrows loaded. It showcases all the signs and features the wads have to offer. The entrance displays all signs in white. The middle room shows all possible colors of the signs and cycles through the signs in 5 second intervals. The left room displays the sign mimicry with the sign, relevant midtexture (if any), and the needed balloon for the color. The right room is for the Lua-exclusive features. There is a podium showcasing the Multi-Arrow in red, a rainbow of arrows, an example of sign scaling, and an example of sign parameter delay via Crimson Core Arrows.

Supporters / CoAuthors:
 

Attachments

  • SignComparison.gif
    SignComparison.gif
    28.1 KB · Views: 2,587
  • K_ColoredArrows_V2.zip
    63 KB · Views: 143
  • Colorable Soc Signs.png
    Colorable Soc Signs.png
    51.4 KB · Views: 2,332
  • Colorable Lua Signs.png
    Colorable Lua Signs.png
    63.6 KB · Views: 2,317
  • Sign Rainbow.png
    Sign Rainbow.png
    49.9 KB · Views: 2,590
  • K_ColoredArrows_V3.zip
    206.2 KB · Views: 94
  • Sign Shop.png
    Sign Shop.png
    164.1 KB · Views: 1,545
  • K_ColoredArrows_V3.1.zip
    200.9 KB · Views: 132
Last edited by a moderator:

D00D64

Probably Responsible
Moderator
Judge
I'd say your wad needs to be "KL_" for its Lua content, but since this is an asset wad, I guess it doesn't matter too much. Welcome to releases!
 

Charybdizs

>WTB lamp oil
Administrator
Judge
You rock! I am all on board with this! I was actually wanting some sort of ability to color remap textures for this purpose exactly, but I'm not a coder and couldn't implement this sort of thing myself.

I would have recolored them all as manual new textures, and meant to do so, but in the case of my crimson core arrows, I was like, "do I really want this many alt colors of an 11 frame texture bloating up the resource wads and filesize?"

This is a wonderfully hacky way to do this! It had me jawdrop! I have one criticism, though. Why use the balloon object? That means this won't work in any levels with balloons used, such as balloon panic, or monster monarch, or w/e. Why not just make a custom object to serve the same purpose? ^^
 

Lach

he/him
Moderator
Sonic Team Junior
Kart Krew™️
Judge
I'd say your wad needs to be "KL_" for its Lua content, but since this is an asset wad, I guess it doesn't matter too much.

There is no Lua, it's done entirely with SOC. Mappers are able to use this without forgoing Record Attack eligibility!

Also, Chaobrother—while the filesize is already tiny and doesn't warrant any update, you should consider looking into the condensed naming system. Each sprite in this WAD seems to have left- and right-side variants, which you can actually merge into one lump using these conventions! For instance, the lump labelled SDARAL can be renamed to SDARALAR, allowing you to remove SDARAR.
 

D00D64

Probably Responsible
Moderator
Judge
Oh wow, I didn't even notice this was all SOC, I'm so used to Lua things that I didnt even think of it. Neato!
 

Chaobrother

Member
Charybdizs: The Balloon object is the most flexible way to get any skin color without modifying the game to my knowledge.

With that being said V2 is now out! Most of the vanilla Kart have been added and a much more flexible Lua version of this script is now included.
 

Chaobrother

Member
Its time for a long overdue update! Colorable Signs is now at V3 with more signs, and a brand new test map.
Soc:
  • Added Thing Types 2237 and 2238, Colorable Gold Arrow. These signs use resources from textures.kart
  • Added Thing Type 2237, Colorable Honeybee Industries Arrow. This sign uses resources from patch.kart
  • Added Thing Types 2239 - 2242 Colorable SD2 Warning, Boost Warning, Invincibility Warning, and U-Turn. These signs were made by me.
  • Added Thing Type 2243 Animated Double Arrow and 2244 Colorable Giant Hand. These signs were contributed by Charybdizs.
Lua:
  • Removed the green Sonic Riders Arrow with the black background to from the Multi-Arrow to make room for the new static signs.
  • Added Thing Type 2245 - Lua Colorable Animated Double Arrow and Thing Type 2246 - Lua Colorable Giant Hand. The graphics were contributed by Charybdizs.

Other:
  • Replaced V2's test map with the Sign Shop. It should do a much better job of showing off the capabilities of SOC and Lua script. Load all 3 files to try it out!
 

Chaobrother

Member
The signs have been updated to v3.1. This is a minor update which fixes a large oversight made at the beginning.
  • The signs now use individual sprite names so they can be used independently without needing signs from previous sprite frames to work.
  • Sprite names added: CCAR, KVAR, BAR1, BAR2, DTA1, SCVA, SRA1, SRA3, PGAR, HIAR, DTA2, CHHD, GDA1, GDA2 ,SDW1, SDW2, SDW3, and SDW4. CHRY was replaced by DTA2 and CHHD. You should be able to remove unneeded freeslots from the lua script, but conflicts will arise if you alter A_MultiArrow.
  • The signs now have a "Colorable Signs" category in Zone builder.
  • Minor texture changes were made to the Sign Shop.
  • The lua script is now spelled correctly.
 

Who is viewing this thread (Total: 1, Members: 0, Guests: 1)

Top