Pixel art recoloring, ultras, cat ears

It’s my birthday tomorrow! Happy birthday, me. The team’s on break for the rest of the year, and I’m starting my own break as soon as I post this. (It’s a famously good idea to post an update right before going on holiday) One quick order of business before we get into the changelog:

Mapmaking rewards: We’ve been trying to reach you about your mech’s extended warranty. Only four of the eleven of y’all who got this high-tier reward have responded and made your map with me. If this is something you wanted to do, check yer email and sign up for a slot! We’ll have a good time chatting! I’m delightful!

How we recolor pixel art

Enough was enough; I’ve felt overly constrained by the available colors in the portrait maker for a long time. We finally pulled the trigger on reworking the coloring system to be able to take any base color and automatically generating a palette from it instead of hand-crafting each available option.

New mech palettes

Let’s take the opportunity to go through how the recoloring system works in Lancer Tactics! We’ll be looking at the mech tokens instead of the pilot portraits because they’re a little more straightforward, but we use the same technology for both. Here’s what a mech token looks like on disc:

raw tokens

Also shown above are our red/green/blue “index” color palettes. These are sequences of seven pixels of various lightnesses. The color of the index pixel on the mech indicates what channel a pixel belongs to (i.e. should it be set to our primary, secondary, or glow color) and its lightness (i.e. darker reds will end up being darker). Pretty straightforward so far!

But now we need some new colors to swap in. Our old system used a series of handcrafted 7-pixel palettes of increasing lightness. Here’s me doing a manual swap-in using aesprite to show the process:

manual recolor

And this worked well! The keen-eyed among you might note that these handcrafted palettes were not linear shifts in lightness; check out how the center lilac palette is warmer in its lighter tones and cooler in its darker ones, or how there’s an abrupt shift in lightness the rightmost yellow. These values were selected with an artist’s eye for better overall effect.

However, the need to manually create each palette took time, which meant that we were always going to be limited in the number of colors we’d be able to provide in the portrait maker. Our greens were bereft; our turquoises ghostly in their lack. If we could find a way to automatically generate palettes that used artistic principles to make good-enough replacements, my hope was that the dip in quality for individual palettes would be made up for in the dramatic increase in range.

And that, my friends, is what we did. Using the OKHSL color space, it’s easy to make an array of “base” colors. After some toying around, I settled on two sets of a rainbow; one high saturation, one low saturation, with each hue given a small range of possible lightnesses. With one of these selected as our base, we can spin out six more colors (three getting lighter, three getting darker) for a full palette.

base generation

“But, Olive!”, I hear you say, “I thought you just said we cannot simply linearly shift a color up and down in brightness and get an artistically pleasing result!”

This is true. Thankfully, we have the wisdom of our ancestors to fall back on. And by ancestors, I mean a 12 year old tutorial on color theory for making Minecraft skins. It’s a good read, but we’ll be specifically copying their “Arc Method” as shown here:

arc method

In addition to shifting brightness, we can shift hue and saturation as well. And how exactly we do that that is where the human element can re-enter.

toneramp values

This ungodly thing is a “toneramp”. Ironcially, it’s a lot less human-readable than what we’ve seen til now. But let’s back up a bit. There are three knobs we can turn when spinning the base color out into the rest of the palette: Hue, Saturation, and Lightness. Modifying hue can make a color warmer or colder (ie more towards yellow or blue). Modifying saturation makes it closer to or further away from grey. Modifying lightness… well, I hope you can guess what that does.

Image files, conveniently, are also typically encoded with three numbers: Red, Green, and Blue. With toneramps, we’re hijacking those to actually interpret as Hue/Saturation/Lightness shifts (not respectively). We have the midpoint - 128 - interpreted as “no change from base”.

There are two things it tells the system: the “red” channel, the top number, tells the system how much to shift the lightness; higher numbers are lighter, lower numbers are darker. The “green” channel, the second number, tells the system how much to make the hue warmer (less than 128) or colder (more than 128). Currently we’re automating the decrease in saturation towards both ends of the palette as per the Arc Method, but may end up having the “blue” channel eventually defining that.

So! Given an automatically-generated base color and a human-crafted toneramp, we can generate a new palette:

base color plus toneramp equals palette

The cool thing about this is that it’s multiplicative; we can handcraft just a handful of toneramps, and then use any base color with that toneramp. In the current build, we have four: Standard, High Contrast, High Hueshift, and Inverted. Here’s me going through them one at a time:

all toneramps, one after the other

It’s kind of subtle, so here they are side by side.

all toneramps, side by side

We’re still tuning the available colors and toneramps (imo the mechs are currently coming out too dark). Has this unlocked previously impossible chromatic desires in your heart? Can you even tell the difference? If you play with this, I’d love to hear your take.

Changelog

New stuff!

  • Gen has finished out the PC mechs, and has dived into the NPCs. Check out her flex on this Barricade’s stripes wrapping around a curved surface!

New NPCs

  • Another batch of portrait assets from Martina incl, finally, cat ears!

Cat ear portrait

  • Recon + Control sitreps. That’s all of them!
  • New templates: Completed Commander, and got Veteran and Ultra in with all their base kits and a scattering of optionals.
  • Implemented rest of the optional kits for: berserker, witch, rainmaker, scout, sniper, and sentinel. Six classes down in about a week… 24 more to go.

UI

  • Clicking on lancers doesn’t automatically start their turn; you can see what stuff they have first.
  • Can cancel out of your standard move to click around and inspect stuff instead. auto-start turn when you only have one PC
  • Fade LOS area in and out while moving the mouse around, added short delay before doing so
  • Can cancel out of a NPC telegraph to tell the game to not show it again for the rest of this session. The era of endless Stampede Defense prompts is (optionally) over!
  • Added button in options to reset the list of skipped telegraphing, in case you get separation anxiety about your Stampede Defense prompts and want them back.

Editor

  • Add triggers that allow you to disable zones within X tiles of a given tile; can be used in sitreps to prevent having zones that spawn enemies near objective zones
  • Can manually set NPC tier.
  • Reinforce triggers can set NPC tier automatically to match the PC license levels.
  • “Emit trigger signal” event can emit multiple signals when given an array – this allows you to e.g. damage all units in a given list!
  • Maps can now opt-out of being modified by Instant Action settings; e.g. one can have a custom sitrep but still use IA opfors (monument bay), or it can completely eschew IA and totally do its own thing.
  • Zone tool shows and can edit what sitreps are available to be played on the current map. Can remap expected zone IDs to alternate ones on a map-specific basis.
  • Add an event to trigger pilot barks.
  • Made a “edit sitreps” modal to dramatically increase the turnaround time for making and fixing sitrep triggers. Will be player-facing, so sets the groundwork for folks to eventually be able to upload their custom sitreps to mod.io. Also will serve as a additional examples for people to see how the trigger system works.

Sitrep editor

Fixes & minor stuff

PC

  • deployables take burn at end of owner’s turn and trigger turn start/end effects e.g. hive drone
  • size 2+ units can stand on “invalid endpoints” that are smaller than them; ie your tortuga is no longer blocked by a few lil cars
  • Can move payloads that are +- 3 spaces from you, to help prevent them from getting stuck
  • manticores castigating KIA the pilot, melting down removes ability to repair mech
  • smoke mine smoke expires on triggering unit’s next turn, not its placer’s next turn
  • thermal charge damage type changed to explosive
  • Vanguard 3 can’t trigger against targets it can’t see
  • fix PCP always deploying in “attract” mode
  • can take a quick action to clear PCP immobilization
  • BTWIKE averages non-attack damage (e.g. gravity gun, grenades)
  • MC hunter only procs on hit
  • impaired ghast drone does not mean your attacks through it are impaired
  • standing up does not end the protocol phase (rule bend to make overeager-to-stand AI not lose their ordnance)
  • being dazed does not end protocol phase automatically; need to be able to continue SEKHMET (other protocols are still unavailable)
  • uncle correctly prohibits off-turn usage until the start of next turn
  • unstoppable doesn’t trigger on misses (improved)
  • Mechs can make eng checks to stop a meltdown
  • fix invigorate not being able to select past the first target
  • fix bug where limited charges would refill if you looked at their tooltip

NPC

  • goliaths don’t re-crush-target multiple times
  • add missing attack bonus for hive HK nexus
  • commander voice of authority actually spends the reaction
  • NPCs use their systems bonus for their frag sig, allied invades auto-hit
  • NPC basic attacks get a bonus by tier
  • NPC mechs can’t double up on the same quick tech twice
  • enemies go first in a round if players went last the prev
  • fix blur causing the witch to treat other targets as invisible oops lol

Editor

  • stairs should not be difficult terrain/an invalid endpoint
  • invalid-tile shunting ignores fall damage
  • editor smoothness improvements; uses gridmap previews instead of rebuilding the map during single tool strokes

UI

  • fix omnigun popcorn text damage amount
  • persistent objective pointer arrow for payloads
  • fix attack preview showing “+ tech attack” when using smart weapons
  • snap tooltip left/right if up/down doesn’t have enough space
  • fix camera autorotation getting you looking head-on when coming from top-down
  • remove bombard and sentinel from everest token list since they’re size 2 now
  • importing NHP pilot files sets their colors to grey
  • ending mission mid-zero-stress-meltdown still counts as having melted down
  • can spend your last repair as an everest on structure

In the homestretch

With this as the last update of the year, we only have three months left for our original 100% core-book-implementation goal. What are the current projections for what we’ll get done in that time?

  • We’ll get the rest of the PC talents (Skirmisher + Siege spec) and most if not all of the NPC class optionals.
  • As I said last update, NPC templates are looking a lot more scattershot: of the ones we haven’t already finished, I think we’ll be able to knock out the other simple ones (Mercenary, Exotic, Spacer, etc) and a decent chunk if not all the optionals for Ultra & Veteran. Templates that require more significant enginework (Monstrosity, Pirate, Ship, Vehicle, Squad) are going to be left to last and I’m not confident we’ll get to them in this Kickstarter period.
  • Module editor work has continued to go slower than expected since my focus is still on content implementation. I’d like to get it out the door as soon as we can, but doing so too early risks needing to make format changes that can break people’s stuff they’ve made with it. Not that that’s stopping folks; GavstarB basically made a module without the connective tissue by publishing each map individually.
  • I know that I said that mod support is a post-Kickstarter future thing, but the aforementioned GavstarB has pulled off a minor miracle in my eyes by decompiling the game and building a modloader themself. We still can’t officially support modwork because we don’t have the time + may need to make fundamentally breaking changes in the future + need to get a legal license drawn up to make the decompiled source available. But hot damn! Wow! Extremely cool to see what’s possible!
  • We’ve super outgrown our thread on PilotNET. We’ve got a draft of a dedicated discord set up, but are waiting until after the holidays to launch it. I am reluctant to put our eggs in a corporate-controlled community discussion area (though I <3 the itch forums) but this is where all the kids hang out these days.
  • I expect a “coming soon” Steam page to be up well before March, to help transition us into the post-Kickstarter era.

Have a happy new year! And again, happy birthday to me specifically. ~ Olive

Draft of all NPCs, foliage, Mod.io maps