Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2

Author Topic: Graphics support for procedurally-generated races  (Read 3348 times)

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Graphics support for procedurally-generated races
« on: April 07, 2016, 01:27:13 am »

This thread is in response to concerns in other threads that the upcoming myth generator's capacity to generate wholly new races will functionally break graphics sets, since currently, procedural creatures exist wholly outside the raws.  They exist inside uncompressed saves as less-than-clear names like TITAN_21 while in-game they appear as a Blue Night Hag or "Worrygears the Frenzy of Wildness" or something, making association of the two difficult.

Broadly speaking, how I envision this would be that modders produce some general-purpose graphics, and then when players come across a procedural creature, they have some method of associating it with one of their graphics tiles.  For example, if there is a creature that is shaped like a three-eyed skinless dimetrodon, modders might have made a dimetrodon-shaped graphic already to associate with it.

Basically, there should be some sort of method of adding a tag in the graphics section that will provide users the ability to make [CREATURE_GRAPHICS:MYTHIC_RACE_2] a set of graphics, especially if they will be playable instead of dwarves.  (That way, we can have indicators of different professions more specific than color-coding job groups.) To that end, there needs to be a way to see (possibly by legends mode or some mythic mode) a list of "known" races (to prevent spoilers) and their descriptions, plus what label to throw onto the graphics raws to associate with the graphics. 

From there, I expect some sort of third-party tool to arise to help automate some of that process of token updating, but that's not something that is necessary for being hardcoded.

...

Also, while I'm asking for graphics support, could you please get around to caste-level support for graphics?  Especially when mods make castes have significant differences, it can be really important.
« Last Edit: April 10, 2016, 03:26:32 pm by NW_Kohaku »
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #1 on: April 07, 2016, 01:39:34 am »

So. I'll re-iterate what I've said: As it stands, this is already a concern as graphics are ALREADY broken with respect to generated creatures. The impending update will magnify this problem and might draw attention to it, but if it hasn't been unfucked by now it's not any more likely to get unfucked soon.
Logged
On DF Wiki · On DFFD

"Hey idiots, someone hacked my account to call you all idiots! Wasn't me you idiots!" seems to stretch credulity a bit.

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #2 on: April 07, 2016, 01:49:59 am »

I can see this working with an interface not entirely unlike the one for picking a burrow's symbol.  You come across a creature with a vanilla tile, look at it, and one of the options is to re-assign its image.  You would only see the DEFAULT image in the selector, though if there is room a representative set of professions/variations might appear while a DEFAULT image is selected.

The challenge with this is the sheer number of images in a complete graphics set, not to mention the extras that might be hanging around specifically for this exercise.  IIRC, the graphics are all stitched together into a single texture with no tie back to the original filename... so that's out.  Something like menu categories might work, though.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #3 on: April 07, 2016, 02:13:05 am »

Though I suspect that a feature of such complexity might be low-priority even within the category of graphics support. If Toady works on more tileset support, I assume that expanding into giving plants, terrain, items etc the same foundation for tiles that creatures do would be higher up on the list. :V
Logged
On DF Wiki · On DFFD

"Hey idiots, someone hacked my account to call you all idiots! Wasn't me you idiots!" seems to stretch credulity a bit.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #4 on: April 07, 2016, 09:09:40 am »

Wonder if we could smush mifki and Japa together, collect the goo that comes out, and bake that into the graphics code?
Logged

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #5 on: April 07, 2016, 10:06:20 am »

Dirst's suggestion would be user-friendly but take work on Toady's part. My suggestion would be much less user-friendly, and probably have most people using a third-party tool to work, but would require rather little effort on Toady's part.

In fact, it's possible to use DF Hack to find out the raw name of a procedural creature and put it in one of the graphics raw files so that certain titans or werecritters had graphics. (There's a plugin that lets you check populations, and I know that lists the HFS and simply has "CLOWN"_11 innumerable, "CLOWN"_12 innumerable, etc.)

Phoebus made a set of [CREATURE_GRAPHICS:TITAN_1] through [CREATURE_GRAPHICS:TITAN_200] tokens in the graphics files, which means they all look the same, but there is, at least, an icon for them, so it's entirely possible to have graphic for a procedural creature. 

What I'm asking for is to make the raw name of particular creatures apparent without unusual third-party attempts to see the code.  Of course, I suppose you could make something DF Hack-based like this visualizer that can actually plunder the internal data for certain key traits (like, say, blob versus quadruped, body material, and special attack,) and choose from a selection of graphics to represent them.

... Actually, the more I think about this, the more I think I could probably do this straight through DF Hack now...
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

Adrian

  • Bay Watcher
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #6 on: April 07, 2016, 10:53:28 am »

Listening to Tarn's talk (around 22min in) it seems the procedurally generated races are all based around template animals (Like Clowns are):
Quote
small contemplative lizards with exposed brains
Quote
tiny cackling serpents with mischievous smiles

Isn't it easiest to just have the generator copy whatever [CREATURE_TILE:] the template animal is referring to, and maybe give it a unique colour?
Logged

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #7 on: April 07, 2016, 10:58:37 am »

Ahah. And now we see the weakest link in the generation: the template. That could be exploitable, yes. :V
Logged
On DF Wiki · On DFFD

"Hey idiots, someone hacked my account to call you all idiots! Wasn't me you idiots!" seems to stretch credulity a bit.

NW_Kohaku

  • Bay Watcher
  • [ETHIC:SCIENCE_FOR_FUN: REQUIRED]
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #8 on: April 07, 2016, 11:09:22 am »

Listening to Tarn's talk (around 22min in) it seems the procedurally generated races are all based around template animals (Like Clowns are):
Quote
small contemplative lizards with exposed brains
Quote
tiny cackling serpents with mischievous smiles

Isn't it easiest to just have the generator copy whatever [CREATURE_TILE:] the template animal is referring to, and maybe give it a unique colour?

Well, new graphics should be produced for a few reasons:

1. You want snake-like titans to look substantially different from a garden snake, just from a player-identification standpoint.  When I was making giant brown recluse spider graphics, I didn't just copy the GCS and recolor it because the difference would be too subtle for most.

2. There are some creatures rather different in type from generic creatures, I.E. dimetrodon clowns, which would need accounting for...

3. You'll probably want to add little features to signify special properties.  I.E. a flesh blob with fire breath might be a red blob with fire around it, while a flying metal blob with webs might have wings on a gray blob with a spiderweb on the edge.
Logged
Personally, I like [DF] because after climbing the damned learning cliff, I'm too elitist to consider not liking it.
"And no Frankenstein-esque body part stitching?"
"Not yet"

Improved Farming
Class Warfare

JesterHell696

  • Bay Watcher
  • [ETHIC:ALL:PERSONAL]
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #9 on: April 10, 2016, 01:51:58 am »

I'm not sure how I feel about this suggestion, I'm generally against do it for the modders/mods type suggestions in any games forums but I really like the idea.... troublesome.
Logged
"The long-term goal is to create a fantasy world simulator in which it is possible to take part in a rich history, occupying a variety of roles through the course of several games." Bay 12 DF development page

"My stance is that Dwarf Fortress is first and foremost a simulation and that balance is a secondary objective that is always secondary to it being a simulation while at the same time cannot be ignored completely." -Neonivek

Shonai_Dweller

  • Bay Watcher
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #10 on: April 10, 2016, 08:53:36 am »

I'm not sure how I feel about this suggestion, I'm generally against do it for the modders/mods type suggestions in any games forums but I really like the idea.... troublesome.
Support for graphics and a large amount of customization is part of the plans. This is the best time possible to make this suggestion as it seems like we're about to enter a phase which could have a negative impact on current support (locking out one of the most interesting parts of the game in the worst case).
Logged

Random_Dragon

  • Bay Watcher
  • Psycho Bored Dragon
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #11 on: April 10, 2016, 10:18:33 am »

I'm not sure how I feel about this suggestion, I'm generally against do it for the modders/mods type suggestions in any games forums but I really like the idea.... troublesome.

Which is again a good thing that the idea already is supported by Toady, just not high on the to-do list.

And giving modders more toys to play with is good. Eventually it leads to good ideas getting brought into the game earlier, in some cases. :V
Logged
On DF Wiki · On DFFD

"Hey idiots, someone hacked my account to call you all idiots! Wasn't me you idiots!" seems to stretch credulity a bit.

Glatux

  • Bay Watcher
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #12 on: April 12, 2016, 09:09:54 am »

My idea would be to make a script/program with a folder that contain various sprites that look trough the procedurally-generated creature select a sprite depending on the template and then paste other sprites on top of it depending on the detail.
Ex : creature is humanoid so it pick humanoid_base(.png), it has blue scale so it apply texture_scale on it and color it blue(apply blue filter), then it apply details, the creature has 1 eye so it paste eye_1 on it, it has claws so it paste claws_2hands on it, etc...
And then you link the creature with the output of the script/program
Logged

Dirst

  • Bay Watcher
  • [EASILY_DISTRA
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #13 on: April 12, 2016, 10:09:31 am »

My idea would be to make a script/program with a folder that contain various sprites that look trough the procedurally-generated creature select a sprite depending on the template and then paste other sprites on top of it depending on the detail.
Ex : creature is humanoid so it pick humanoid_base(.png), it has blue scale so it apply texture_scale on it and color it blue(apply blue filter), then it apply details, the creature has 1 eye so it paste eye_1 on it, it has claws so it paste claws_2hands on it, etc...
And then you link the creature with the output of the script/program
This was my general understanding of how to do forgotten beasts and such, but remember that you get at most 32x32 to work with, and still have to add bits to distinguish professions.  The level of detail can't be too deep for playable races.
Logged
Just got back, updating:
(0.42 & 0.43) The Earth Strikes Back! v2.15 - Pay attention...  It's a mine!  It's-a not yours!
(0.42 & 0.43) Appearance Tweaks v1.03 - Tease those hippies about their pointy ears.
(0.42 & 0.43) Accessibility Utility v1.04 - Console tools to navigate the map

Glatux

  • Bay Watcher
    • View Profile
Re: Graphics support for procedurally-generated races
« Reply #14 on: April 12, 2016, 10:13:16 am »

My idea would be to make a script/program with a folder that contain various sprites that look trough the procedurally-generated creature select a sprite depending on the template and then paste other sprites on top of it depending on the detail.
Ex : creature is humanoid so it pick humanoid_base(.png), it has blue scale so it apply texture_scale on it and color it blue(apply blue filter), then it apply details, the creature has 1 eye so it paste eye_1 on it, it has claws so it paste claws_2hands on it, etc...
And then you link the creature with the output of the script/program
This was my general understanding of how to do forgotten beasts and such, but remember that you get at most 32x32 to work with, and still have to add bits to distinguish professions.  The level of detail can't be too deep for playable races.

I think professions would be differentiated pasting clothes on top of everything else
Logged
Pages: [1] 2