How to make my mod compatible with RGB sliders? (1 Viewer)

Kotebegemote

Content Creator
Joined
Dec 7, 2017
Hi, I made my first mod and I want that my clothes to change color. Can anyone make a detailed guide, step by step how to do this in Adobe Animate CC? I tried to find this explanation through the search, in the tutorials section and in the help section, but did not find it. I understand the basic concept that is provided in the SDTMod template, that for each piece of clothing I need to create an additional black layer, which need to convert into movie clip, which will in result give different color gradients. Since there is no explanation how correctly to do this technically, I tried to do it as the way I understand this, but so far without success.
 

stuntcock

Content Creator
Joined
Jun 5, 2012
I understand the basic concept that is provided in the SDTMod template, that for each piece of clothing I need to create an additional black layer, which need to convert into movie clip, which will in result give different color gradients.
The instance of your black MovieClip must be named "rgbFill" or "rgbFill2" (without the quotation marks). You've probably already seen a similar pattern in the naming of costume parts as "rightThigh", "chest", "back", etc. These are essentially "magic words" employed by SDT. If they're missing (or misspelled) then the game won't notify you or complain about the absence; your mod simply won't work correctly.

If you're having trouble then I would encourage you to lookup a working example (by downloading the FLA source file for a similar SDT mod) and then tinker with it to learn how it works. You can copy-paste parts of that FLA file into your own to help overcome challenges in your project. If you're really stuck then you can always upload your own FLA file and ask other modders for assistance.

The Bowtie Collar mod focuses heavily on RGB adjustment so that might be a useful example to review. You can also find the entire collection of Dante's FLA files available for download; they don't all include RGB functionality but there are useful examples for many other features (such as breast slider support).
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
Thanks for the answer. I used the SDTMod.fla template, there are no rgbFill and rgbFill2 layers. Bowtie Collar is certainly a good example of how it should be when everything is already done. Yes I see that there are two layers of rgbFill and rgbFill2, but the problem is that I'm new to Animate CC, and do not know how to make it so that it was like in this example. It is difficult to understand seeing only the finished result. At this stage, I only know how to make a simple mod in Animate CC using the standard templates to which I have applied my textures. Everything works fine except for the ability to change color. On this site I found good and detailed and understandable tutorials, thanks to their authors, so I thought that if it was not difficult, someone could do something similar for this topic
 

stuntcock

Content Creator
Joined
Jun 5, 2012
Yes I see that there are two layers of rgbFill and rgbFill2
Those layers exist for the sake of the modder's convenience. They're meant to improve the ease of editing the file (e.g. when toggling layer visibility or when altering the visual priority of layers). The fact that the layers are given descriptive names is not significant. You can rename the layers, or collapse everything onto a single (very messy) layer, but doing so will not have any effect on the SWF output file nor the in-game behavior of the mod. The only important distinction is whether or not a given MovieClip instance is named "rgbFill" (or "rgbFill2"). That's the only factor which SDT's code cares about.

do not know how to make it so that it was like in this example.
You change the name of the MovieClip instance.

This is done by selecting the element (left-click while using the Selection or Sub-Selection tool), switching focus to the Properties pane (if it's not already visible), and typing the desired name into the textbox which appears at the top of the Properties pane. This textbox will often be empty; most elements in SDT mods are left unnamed aside from the few which require "magic word" names (such as rightThigh, rgbFill, etc).

On this site I found good and detailed and understandable tutorials, thanks to their authors, so I thought that if it was not difficult, someone could do something similar for this topic
Tutorials tend to focus on topics of moderate difficulty which involve weird and unintuitive SDT stuff.

The Newbie Guide focuses heavily on Character Folders, but it doesn't explain filesystem basics (such as "subfolders can be nested", or "here's how to rename a file") even though a few users have failed due to a misunderstanding of filename extensions. SClover's guide to dynamic hair animation was an essential learning resource for me, but it doesn't actually explain how to draw hair. Faceless' Loader template contains friendly step-by-step instructions, but if the reader has zero experience with Flash or ActionScript then they will probably endure a lot of painful trial-and-error before publishing their first mod.

Because @Konashion chose to develop his game in Flash, the modding work has usually been done by amateurs rather than actual novices. Flash is licensed software and its paywall is a major psychological hurdle (a trial option exists but it isn't very popular). There are relatively few people who get involved in Flash modding without prior exposure to Flash (e.g. by attending an animation class, through familiarity with other Adobe products, via the workplace, etc). Tech support tends to focus on the peculiarities of SDT (e.g. "here is a list of magic words") rather than the Flash itself (e.g. "here's how to rename an element so that its name matches a magic word"). We might need to teach new modders how the breast slider works, but we rarely need to explain what a Tween is and how to create one. Tutorials are usually born from a modder's desire to stop answering a perennial question -- or occasionally from someone's desire to share a useful discovery (example).

I don't mean to disparage you or deny you support. I'm happy to help, and if you're still stuck on this particular problem then please share your FLA file and I'll show you how to get the RGB feature working. I'm simply trying to explain why this particular Tutorial doesn't exist.
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
Well, okay, I spent some time to understand how to do these things and using the most reliable trial and error method I got the rgbFill layer to look like the Bowtie Collar example, but the color still does not change. Then I thought maybe the reason in something else, and remembered that I did not say that I'm making not the classic draw mod, I'm making photorealistic boots, the textures were edited in Photoshop, and then imported into Animate CC. So the question is, can the game change the color of the photo textures?
 

stuntcock

Content Creator
Joined
Jun 5, 2012
So the question is, can the game change the color of the photo textures?
The game can change the color of a black shape named "rgbFill" so that its color become something else (such as red, blue, purple, etc). If all of the photorealistic details are layered on top of the featureless black shape (in the form of partial-alpha transparencies) then yes: the RGB sliders will behave as expected.

If you haven't setup your drawing in the form of (big black shape) + (translucent shading and details and everything else) then the RGB slider approach will be less effective. If you have an opaque photograph of a boot, layered on top of a black boot-shape named "rgbFill", then the game's slider-driven changes in the color of the black shape will be useless. The viewer will see only the boot photograph, and they won't be able to influence the appearance of that photograph. The background boot-shape will change color as expected, but nobody will ever notice.

You could look into the +reghue feature of moreClothing, which applies a tint transformation to the entire object. The advantage of this approach is that you're not forced to redesign your artwork. The disadvantage is that the tint adjustment applies to the entire thing (including its outline) which sometimes makes it look out-of-place because its brightness doesn't match the rest of the scene.

Alternatively: share your FLA file. We can check the RGB elements and the layering, to ensure that everything is setup correctly.
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
If you have an opaque photograph of a boot, layered on top of a black boot-shape named "rgbFill", then the game's slider-driven changes in the color of the black shape will be useless.
Most likely everything is exactly as you said, I'm using a non-transparent photo texture. Tomorrow I'll watch the +reghue feature, although I already think it may not complicate and it will be easier to just make several variants of the primary colors, but I have plans to make other photorealistic mods, including hairstyles and in the future it will be good to learn change the color of textures . By the way, where can I put my files if it will be such a need, file hosting or here, the button upload a file?
 

stuntcock

Content Creator
Joined
Jun 5, 2012
other photorealistic mods, including hairstyles and in the future it will be good to learn change the color of textures
Hairstyle have a dedicated tint-adjustment mechanism. There's a "Her Hair" color swatch on the "Modding" tab of the in-game menu. Hence, it probably won't be necessary for you to include special color-adjustment work within your hairstyle mod, because users are able to fine-tune the hair color (or even change it radically) using standard tools.

It doesn't hurt to learn, of course! I just don't want to waste your time with a redundant task :)

The "rgbFill" feature is, as you've seen, most useful when dealing with vector artwork which can be neatly divided into separate layers (color fill, outline, highlights, shadows, etc). If you're working mainly with photorealistic stuff then it will be difficult for you to employ the RGB sliders effectively, but that's okay. If those sliders don't benefit your mod, or if they're too difficult to integrate, then you're not required to use them.

For example: this mod doesn't use the conventional RGB sliders, but instead relies on the +reghue feature to provide different colors. I could have integrated the standard RGB sliders, but it would have taken more time (and increased the risk of bugs) so I didn't bother.

By the way, where can I put my files if it will be such a need, file hosting or here, the button upload a file?
FLA files can be attached to your posts for sharing purposes. You can also use offsite hosting, such as mega.nz or mediafire.

We try to discourage people from using forum attachments for trivial stuff (such as funny pictures of cats) because the file space is limited. But so long as your files are relevant to mods (WIP files, bug reports, screenshots of errors, sketches for a new idea, etc) or the content is applicable to the board in which you're posting (fanfiction, erotica, sexy screenshots, etc) you're welcome to attach and upload files.
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
First of all, Merry Christmas to all, wish you a good holiday.

I was wondering what would happen if I made the texture translucent, I set the non transparency to 50% and thought that I would finally see the color change, but no, nothing happened. Then I realized that I was doing something wrong. Next, I decided to just draw a kind of sock and see what happens now, but the same thing happens. So I leave this file here, if you can take a look and tell me what I'm doing wrong.
 

Attachments

example.fla
176 KB · Views: 106

stuntcock

Content Creator
Joined
Jun 5, 2012
So I leave this file here, if you can take a look and tell me what I'm doing wrong.
Minor oversight: your project file didn't include any registerMod statements.

You've named an element "rgbFill", but it's a peer to the "rightFoot" element. It needs to be a child. While browsing through your project, I need to be able to eventually find something named "rightFoot" and double-click on it, and then find something named "rgbFill" inside of that. That navigation or traversal idea is (in a very loose sense) what the SDT game code will do when it tries to apply the user's RGB slider adjustment onto your artwork at runtime.

SDT modding relies on magic words. If you provide SDT with the name "rightFoot" then the game knows to draw your artwork at a particular position on a particular layer. But if you tell it "rgbFill" then that's not enough information; SDT doesn't know whether the sprite ought to be drawn on the girl's left calf or her right calf (or her elbow, if we want to be really pedantic). So the "rgbFill" MovieClip must always have a parent whose name is a magic word. In fact, this applies to everything. If your FLA file includes miscellaneous elements (which are either nameless, or which have non-magic names such as "shadow", "detail", "boot #1", etc) then the game will simply ignore them unless they're children of a MovieClip which already has a well-defined position and role (via its magic name).

-------------------​

I've left your grey sock in-place but reduced its alpha value, so that it acts as a permanent shading layer on top of the rgbFill stuff. As a result, bright colors (such as pink) will appear muted and muddy. Hopefully you can imagine (or experiment) to see that the flat grey overlay could be replaced with a set of actual shadows and highlights -- which will then appear in conjunction with the user's chosen color.

There are exceptions at the extreme ends of the scale. If the user chooses pure white then any overlying highlights will be washed out; if the user chooses pure black then shadows will become invisible. As modders, we can mitigate this problem by limiting the user's freedom of choice, or by diluting their options (the Bowtie mod uses the second approach, refusing to display a true black) ... or we can just accept the problem and allow users to create ugly results if they insist on pure black or pure white.

Please note that the rgbFill technique still won't work very well with photorealistic images -- not even if you overcome all of the Flash problems. I believe that you should try to use the moreClothing +reghue option instead. You can publish a single "canonical" version of the mod, or a few color variants (based on a few different raster images prepared in Photoshop) and then allow users to fine-tune the hue and tint values via Loader sliders.

example - edited.fla
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
Thank you very much, you helped me understand what the problem was. Everything turned out to be much easier than I thought. Frankly, from the very beginning I assumed that the rgdFill layer should be inside the main layer, but for some reason threw this option out as wrong, but it turned out the opposite. Perhaps the example with Bowtie Collar confused me, it gives the impression that rgbFill is just outside. What I did not know is that even a drawn image should be transparent, have an alpha channel. By the way, then it's not clear how Dante's mods work, they are completely different, they do not have rgbFill layers, the details often do not have transparency, but anyway they can change color.

Minor oversight: your project file didn't include any registerMod statements.
I just hurried and forgot to do this in this file, but I certainly register other files, otherwise I could not compile them. And yes, about the compilation, I tried to publish the file that you sent to me and received errors (something about incorrect registration, charData, modCreator) although I specified everything correctly, then I took and added all the new changes to my file and compilation was successful. It's unclear what the problem is, different versions of Flash?

Well, the last, yes, you're right, transparency is not very good for photo textures, for example, leather boots start to look like jelly or caoutchouc rubber, it turns out quite funny. Therefore, probably the only option is a few basic colors or the use of +reghue, but as long as I remember you said that there are also some disadvantages. I'll post my mod later, I just need to change something. Since this is a photo texture and there are many details on it, and boots above the knees, it is necessary to minimize the visibility of overlapping borders and details when moving the legs. Probably, something to clean, somewhere to make up. For a knee pose looks good, but with others it becomes noticeable
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
I had another question, but to not create a new topic I'll write here. While making my mod, I noticed one strangeness. The arrangement of the textures on the template in Animate CC and in the game does not match, I thought maybe I'm using some old template, but in the game the layout of the model has changed a little? I read somewhere that if I make a glove mod (which I want to try to do) on old templates, then it may not work correctly in a newer version of the game. And do I understand correctly that the template is an exact copy of the girl's standard posture in the game? I added a screenshot for better understanding
 

Attachments

  • position.jpg
    position.jpg
    162 KB · Views: 108

stuntcock

Content Creator
Joined
Jun 5, 2012
I read somewhere that if I make a glove mod (which I want to try to do) on old templates, then it may not work correctly in a newer version of the game.
The vanilla game doesn't support glove-type mods. @Konashion left abruptly, and so there are several "obvious" modding features which could easily have been included but which are absent from the released game. Legwear (such as socks and stockings) is another notable exclusion.

In the early years, modders compensated for the "missing" categories by drawing gloves (as well as long sleeves) using the BODY mod type. So we had a clothing item being treated as skin (or tattoo), which meant that it behaved oddly when the user tried to adjust the RGB and HSL sliders. As the SDT Loader proved its value (and became generally accepted), some modders chose to implement their work as Loader mods. The artistic process is similar to what you've already done -- but instead of assigning magic names to the pieces of your mod and then trusting SDT to send each magic-named element to the right place, you must include AS3 code snippets which will manually import each of your sprites and draw them in an arbitrary location. When done correctly, this approach puts each sprite directly onto the "intended" layer, bypassing @Konashion's unfinished code. Thus, the artwork will respond properly to slider adjustment and can even stack or layer itself alongside other mods which share the same space. @Faceless has created a template file which aims to make the publishing process friendlier to newcomers, by including all of the standard AS3 code (so that you need only "activate" the relevant chunks of code).

The code-based approach is somewhat brittle. It necessarily makes hardcoded assumptions about the visual hierarchy of game sprites, about the layers used by the game, and about the syntax of Loader function calls. If any of these things change (because a new version of the Loader gets released, for example) then an old Loader mod file might become inoperative. The artwork within the SWF is still perfectly good, but the mod won't work correctly until someone breaks open the file and fixes the scripts (if the author is still around, then of course he can update his template file and republish the mod). If you've found old glove mods which don't work anymore (or if you've seen discussion of such issues) then it's probably due to outdated Loader scripting.

If you want to make a glove mod then I encourage you to use sby's template. Learning AS3 can be a fun challenge for an aspiring programmer, but if it's merely a means-to-an-end (i.e. if you just want to create sexy mods) then you'll probably find it frustrating. Still, you may find it useful to download the Faceless template and explore its contents; the "Her Layout" and "His Layout" elements can help you to understand the composition and layering of body sprites. The Loader template includes some details which are very difficult to mod (such as lips, eyelashes, etc); you're not really expected to do anything with those elements, but simply clicking through them might improve your understanding of the game's inner workings.

I encourage you to publish your work in "vanilla" format because it's more friendly to consumers. Such mods tend to load and unload more cleanly, and they can reliably be combined with other mods (and even loaded piecemeal via moreclothing).

And do I understand correctly that the template is an exact copy of the girl's standard posture in the game?
No, it isn't. The game's animation system uses the word "tween", but the concept is not synonymous with Flash tweens. @Konashion originally laid out his characters in the Flash workspace (and he used this layout as the basis for the template files which he shared with us), but he subsequently fine-tuned the character poses via code adjustments. So your suspicion is correct -- the template is not an exact preview of the girl's standard posture.

Of course, users can make huge adjustments to the character positions (or sizes) via modding. So we usually don't worry about this sort of posing inaccuracy. If your artwork looks good on the Flash canvas then it will probably look good in-game ... even though it may look slightly different.

Note: the knee/leg posing discrepancy is one of the least troublesome ones. The neck/nape/scalp zone of the template includes several geometry errors, which can create great frustration for an artist who is trying to draw a close-cropped hairstyle.
 

Kotebegemote

Content Creator
Joined
Dec 7, 2017
Thanks for the explanation, you are good at it. I did not think that some types of moding for this small and fairly simple game can turn out to be a bit more complicated than it seems at first glance. I will try to understand all this, but I feel that the gloves will have to be postponed for the future, but for now I might try something simpler like headdresses. I hope this will not cause such problems. Honestly, more recently, I had no idea about this game until one person on the forum did not mention her name. Probably Konashion did not expect that his small, but very successful game will have such an active modding, otherwise he would most likely have taken care that it was more accessible. Today's games are a hundred thousand times more difficult, but if developers initially lay down the possibility of moding in their game, it is often not necessary to be an engineer-programmer in order to to do something interesting, it's enough to be an artist or just an enthusiast, even a beginner
 

Users who are viewing this thread

Top


Are you 18 or older?

This website requires you to be 18 years of age or older. Please verify your age to view the content, or click Exit to leave.