Jump to content

[1.4.x] Decal Stickers R2.0 (Custom Flags & Agencies, Instructions to add your own!) March 21, 2018


blackheart612

Recommended Posts

50 minutes ago, DarkOwl57 said:

@blackheart612: How hard/easy would it be to make your own flag? I'm planning on hosting a racing series, and making the flags would be great for numbers, sponsors, etc.

Flags themselves are pretty straightforward; any 256x160 .png can be a flag file. As far as making it available for use with this mod, you'd have to adjust the configuration files for the three parts to include the flag. That in and of itself isn't terribly difficult and I can easily walk you through the process (next chance I get, anyway - bit busy at the moment).

Link to comment
Share on other sites

8 hours ago, blackheart612 said:

@h0yer I was on hiatus for a month, yes, it's fine, especially since the license is GPL as well so you're free to do as you please :) 

Hey, good to see you back up, I hope everything's OK :)

Cool thing!

 

9 hours ago, Dark Lion said:

Would you mind showing your work? I'm savvy enough to remove all Squad and Agencies flags and/or replace them successfully, but precious details are omitted from this quote. I have high hopes I will one day just drop my artsy files in the right folder and they appear for selection in the editor... No cfg manipulation necessary. As it stands, this mod takes me something like 10min to set up due to having almost 50 flags to choose from now... and I have to change cfgs every single time a new flag(s) is added.

Again, would love a demo. Does this effectively eliminate flags you selected from selection in the editor or delete them entirely? Something else? I'd also be grateful to learn how you're planning to manipulate the file paths as such that making changes are much easier. The importance of the folder structure and the lines which call on them is still just beyond my understanding. Very basic.

Feel free to message me instead if this post is considered derailment and you're kind enough to teach.

 

Nah, I guess it's always OK to 'discuss' such things openly, ehehe :D

 

I have only 'repatched' the paths, nothing fancy really.

Adding/removing logos sadly still involves typing them into something and all the clickeroo when changeing the logo in the VAB^^

 

But you can have a look at my GitHub... thingy. It's the actual MM patch for the CRAP minimod. Maybe you can salvage/rewrite it to your purposes.

Link to comment
Share on other sites

Since it's come up a fair number of times on this thread, I thought I'd let y'all know that I started work on a script today that (knock on wood) would let folks modify the .cfg files for custom flags all at once. Very early stages at the moment - it's been a while since I've done any kind of substantial coding so a lot of what happened today was just shaking off the rust. I'll keep y'all up to date on my progress.

Link to comment
Share on other sites

Well, the code's ugly, but it seems to be working as intended. Can't say as much for the mod itself at the moment; I did just copy over what I had from 1.3.0 instead of doing a fresh install like a normal person. Trying to do a fresh install now, and spacedock appears to be down...so it's hard to verify if my code is actually doing anything helpful.

Meantime, I can begin preparations to turn the raw code into something moderately useful. By which I mean I need to add a GUI to it so it doesn't look and work like a gigantic three-day old dog turd...

EDIT: I don't seem to have a Firespitter sub-directory in my GameData folder anymore; guessing that's the issue right there...

Edited by capi3101
Link to comment
Share on other sites

Quick reinstall later and I can verify that my code did add the test flag to the textureNames and textureDisplayNames, but the flag image isn't changing when I hit "next/previous flag". Can't see an obvious difference between the .cfg with the test flag in it and one I haven't touched yet other than the added flag and description (which works like it's supposed to), so I'm not sure what's going on right now. Still progress for the day, I suppose. 

Link to comment
Share on other sites

Thanks @Dark Lion for liking the two previous posts - it reminded me to give you guys an update...

The basic code as it stands now is working for all four part types; I've used it to update my own .cfg files to include the flags I want. Been busy in RL this week, so I haven't had time to work on the GUI; hope to be able to do so soon.

Link to comment
Share on other sites

2 minutes ago, capi3101 said:

Thanks @Dark Lion for liking the two previous posts - it reminded me to give you guys an update...

The basic code as it stands now is working for all four part types; I've used it to update my own .cfg files to include the flags I want. Been busy in RL this week, so I haven't had time to work on the GUI; hope to be able to do so soon.

TBH I'm just as interested in grabbing the patch :P
But keep it up! Sounds like you're on the right track.

Link to comment
Share on other sites

  • 1 month later...

I think I found a small issue with the current version. Maybe someone else can confirm

With the upsized sticker, when you cycle to the shape "Type B" it won't let you cycle through flags. It switches to the default KSP logo and pressing next/previous flag does nothing. Every other sticker/shape works though. The other shapes of the same sticker work aswell, otherwise I would've assumed I messed up the part.cfg

 

Edited by EscaWest
Link to comment
Share on other sites

13 hours ago, EscaWest said:

I think I found a small issue with the current version. Maybe someone else can confirm

With the upsized sticker, when you cycle to the shape "Type B" it won't let you cycle through flags. It switches to the default KSP logo and pressing next/previous flag does nothing. Every other sticker/shape works though. The other shapes of the same sticker work aswell, otherwise I would've assumed I messed up the part.cfg

 

The current build is a bit problematic, but seems like the Type B has a problem in its cfg indeed. I have to check it when I got the time.

 

@Jack5.exe You can copy a decal part you want, change the part name and change the rescaleFactor to a smaller value, see if that works. Don't forget to change the in game name to avoid confusion in selecting it.

Link to comment
Share on other sites

1 hour ago, blackheart612 said:

The current build is a bit problematic, but seems like the Type B has a problem in its cfg indeed. I have to check it when I got the time.

 

@Jack5.exe You can copy a decal part you want, change the part name and change the rescaleFactor to a smaller value, see if that works. Don't forget to change the in game name to avoid confusion in selecting it.

Thank you, it worked, I just don't know how to change the In-game name

Link to comment
Share on other sites

  • 2 weeks later...
19 minutes ago, Saltshaker said:

So how exactly do I get the flags from mods to show up on decals? 

You have to add their information to the four configuration files that govern how the mod behaves (one configuration file for each of the four different decal parts). I built a Python script that does the heavy lifting and had intended to turn it into a utility for general use by the community, but I haven't bothered to work on the GUI (I was going to say 'I haven't had time to work on it', but that would be dishonest). 

Anyway, if you want to do it manually, start with any one of the configuration files (I'd suggest the one in the blackheart/Parts/Stickerbig directory just because you have to start somewhere). Crack it open in a plain text editor like Notepad++ (regular Notepad works in Windows), and then look for the line that begins with 'textureNames ='. Tack on the directory name and the filename of the flag PNG you want to add (e.g., an American flag in the Flags directory might be something like 'Flags\usa'). Once that's done, look for the line that begins 'textureDisplayNames =' and then add the affiliation description (for the American flag, you might say 'USA'). Lather, rinse and repeat with the other three parts configuration files.

Link to comment
Share on other sites

1 minute ago, capi3101 said:

You have to add their information to the four configuration files that govern how the mod behaves (one configuration file for each of the four different decal parts). I built a Python script that does the heavy lifting and had intended to turn it into a utility for general use by the community, but I haven't bothered to work on the GUI (I was going to say 'I haven't had time to work on it', but that would be dishonest). 

Anyway, if you want to do it manually, start with any one of the configuration files (I'd suggest the one in the blackheart/Parts/Stickerbig directory just because you have to start somewhere). Crack it open in a plain text editor like Notepad++ (regular Notepad works in Windows), and then look for the line that begins with 'textureNames ='. Tack on the directory name and the filename of the flag PNG you want to add (e.g., an American flag in the Flags directory might be something like 'Flags\usa'). Once that's done, look for the line that begins 'textureDisplayNames =' and then add the affiliation description (for the American flag, you might say 'USA'). Lather, rinse and repeat with the other three parts configuration files.

Thanks, I'll get to work. Also, @blackheart612 you should probably add something to the effect of this to the OP.

Link to comment
Share on other sites

If I asked nicely, maybe @capi3101 will be nice enough to share it but it's not mine and I hate the fact that people who make nice things get disregarded because I can simply pack it and I have the thread. Most people'll just think that it's mostly my effort. Put forth a permanent post link that you change anytime and I shall link it both in this thread OP and in Spacedock.

Link to comment
Share on other sites

  • 1 month later...
  • 4 weeks later...
1 hour ago, Smart Parts Wanter said:

How would one go about editing CFG files of this mod to make it compatible with tweakscale?

You need to know how to make configs for tweakscale. It's relatively easy, especially if you have module manager and adept at using it as well. Do note that I'm going to overhaul this already simple mod for 1.4.1.

Link to comment
Share on other sites

 


On 25/2/2018 at 3:16 AM, YoloT47 said:
I can't figure out how to add custom stickers, can anyone help

creates a .cfg file and add this,

MODULE
{
    name = TweakScale
    type = free
}

stating in that folder is installed the mod, to more help look in Modulemanager thread

Edited by Dux Aquila
add quote
Link to comment
Share on other sites

Release 2.0

I already changed how adding new stickers worked. Fixed all the issues about having the custom stickers now. Here's the changelog:

 

-Integrated Texture Switch with 1.4 ModulePartVariant for easy adding of own texture

-Updated to 1.4.x

 

---

There instructions on how to add your own stickers in the OP, please check it out.

 

I'm really sorry for lacking to check here from time to time as my bigger mods need more attention. But don't worry, I'm going to keep supporting this. And now it's better than ever.

Link to comment
Share on other sites

13 hours ago, Dux Aquila said:

 


On 25/2/2018 at 3:16 AM, YoloT47 said:
I can't figure out how to add custom stickers, can anyone help

creates a .cfg file and add this,

MODULE
{
    name = TweakScale
    type = free
}

stating in that folder is installed the mod, to more help look in Modulemanager thread

I don't know if you replied to me but if so, I just create this file with notepad and put it in the decals folder? What do I name it?

10 hours ago, blackheart612 said:

Release 2.0

I already changed how adding new stickers worked. Fixed all the issues about having the custom stickers now. Here's the changelog:

 

-Integrated Texture Switch with 1.4 ModulePartVariant for easy adding of own texture

-Updated to 1.4.x

 

---

There instructions on how to add your own stickers in the OP, please check it out.

 

I'm really sorry for lacking to check here from time to time as my bigger mods need more attention. But don't worry, I'm going to keep supporting this. And now it's better than ever.

I'm currently playing on my server which runs 1.3.1, would it be problem if I update this mod anyways?

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...