Zalord's Mods (Update July 19 StopSWFCode_Global) (1 Viewer)

Zalord

Content Creator
Joined
Jun 12, 2013
I make mods to add functionality or to fix issues with the game.

Multiple Backgrounds Mod
This Mod allows you to select backgrounds from a folder you place into a character folder. This Mod is meant to be placed into the $INIT$ folder and will persist through reset.

Here's how you use it:


  1. Place BGLoader.swf into Mods/$INIT$ and update Mods/$INIT$/Mods.txt to include it.
  2. Go to the character folder you want to have multiple BGs in and create a folder called "bgs"
  3. Within the bgs folder, place all of the background images that you want to use.
  4. Within the bgs folder, create a text file "bgs.txt"
  5. Put the filenames of all of the backgrounds you want to use into bgs.txt


Now when you load the character folder that you've modified, a new menu will replace the default background selection and you can cycle through them in the order that they're listed in bgs.txt.

I've also attached an example character folder if you're still confused about how to use it. Just put the folder in the Mods directory.

Big thanks to sby and ModGuy for helping me out. This was my first AS3 project. Some code borrowed from sby's moreclothingV1_2

This is a slightly different version from what I posted the first time. With this new one, you can load .swf backgrounds too. So if you downloaded this early on, make sure you get this updated version.

View attachment BGLoader.swf
View attachment BGLoader.as
View attachment BGLoaderExample.zip

Block Code Loading
This mod prevents other .swf files from applying their own character codes to the character. This can fix issues with some mods which prevents you from automatically loading your own hair file or other character traits, since the stuff in the .swf file is usually loaded last. Usually these .swf files were made without loader character folders in mind, so this is a way around that.

Just add this mod to the character folder in question and make sure it is at the top of Mods.txt. If you want to keep some traits from the .swf, you can use the generate custom save data option in the Modding tab and place that in your own Code.txt in the character folder.
View attachment StopSWFCode.swf
View attachment StopSWFCode.as

Block Code Loading ($INIT$ version)
A global version of my previous StopSWFCode mod. Place this one in your $INIT$ folder and it will prevent other .swf mods from applying their own character code only if the character folder has a code.txt file.


View attachment StopSWFCode_Global.swf
View attachment StopSWFCode_Global.as

Remove custom files from character data.
I mainly put this together to help with generating character codes and figured I'd throw it up here. Keeps the game from including external files when it generates character codes (No more customHair:blah.png or whatever)

This mod goes into the Mods/$INIT$ folder.

View attachment Mod.swf
View attachment Mod.as

Clean Codes
Running this will cause all of the code.txt files in the Mods folder to split into multiple lines instead of all being on one. This makes them much easier to read and modify and they still load just fine.


Code:
charname:Jane Doe;mood:Normal;hair:sdchan;

becomes

Code:
charname:Jane Doe;
mood:Normal;
hair:sdchan;


Place the .jar into the same directory as the Mods folder then run it. Nothing pops up when it runs, so you'll have to check a random code.txt file to check if it worked.

If you're worried about it messing up your codes files, back up your Mods folder first! I've tested it with all of my characters and it didn't break anything, but it's better to be safe than sorry.

The .java file is just the source code. You don't need it for the .jar to work.

View attachment CleanCodes.jar
View attachment CleanCodes.java

Ideas:
-Extract codes from .sdt files
-$INIT$ version of StopSWFCode. (In-Progress)
-Make changes to the "Clothing" button in the "Scene" tab
 
Last edited:

aztlan

Casual Client
Joined
Sep 14, 2013
Re: Multiple Backgrounds Mod

Interesting.

Its probably not possible, but it would be fun to be able to add animated backgrounds this way too.
 

Zalord

Content Creator
Joined
Jun 12, 2013
Re: Multiple Backgrounds Mod

aztlan said:
Interesting.

Its probably not possible, but it would be fun to be able to add animated backgrounds this way too.

I'm sure it's possible. I just tried it out and it doesn't work at the moment.

Right now I'm trying to fix an issue that is preventing other mods from loading. I have a general idea of what's wrong, but I don't yet know how to fix it. In the meantime, I've included an earlier version of this that I wrote, but it has to be placed in the individual character folders instead of just in $INIT$. The .as file of the $INIT$ version is also in the first post if anyone wants to take a look at it.

I'm pretty sure that the issue has something to do with the unloadMod() statement of my Mod being run before the other mods have a chance to load. I'm currently digging through the decompiled loader files to see if there's something I can use.
 

aztlan

Casual Client
Joined
Sep 14, 2013
Re: Multiple Backgrounds Mod

The latest version of moreclothingV1_2 will also load backgrounds in a similar fashion, that is to say it will add backgrounds to the vanilla background menu. The default install adds three backgrounds this way.

This mod loads OK with others in general, but you have to give it plenty of time to load. I believe sby might have had similar issues to your when he first started developing his clothing mod so you might try taking a look at what he did to see if that helps with your issues.
 

Zalord

Content Creator
Joined
Jun 12, 2013
Re: Multiple Backgrounds Mod

aztlan said:
The latest version of moreclothingV1_2 will also load backgrounds in a similar fashion, that is to say it will add backgrounds to the vanilla background menu. The default install adds three backgrounds this way.

This mod loads OK with others in general, but you have to give it plenty of time to load. I believe sby might have had similar issues to your when he first started developing his clothing mod so you might try taking a look at what he did to see if that helps with your issues.

Yep, I actually borrowed some code from sby's mod for this. I had no idea what to do for the buttons so the code for them is pretty much ripped straight from it. I'm currently looking through the rest of it to see if he ran into any problems like this.

And yeah, timing seems to be a big part of the issue. Sometimes it works perfectly, sometimes it doesn't. I need to get it to the point where it always works.

EDIT: Well I did something and it seems to be working fine now. I've put the new version in the original post. Going to keep testing it though.

EDIT2: I threw together a quick version which can also load animated background .swfs.
 

ModGuy

Content Creator
Joined
Feb 17, 2011
Re: Multiple Backgrounds Mod

Place all content in the OP so people can find it.
Consider including source for derivative work.
Remove obsolete versions of the mod to ensure users are up to date.
 

sby

Content Creator
Coder
Joined
Sep 11, 2012
Re: Multiple Backgrounds Mod

MG said:
Place all content in the OP so people can find it.
Consider including source for derivative work.
Remove obsolete versions of the mod to ensure users are up to date.
>_>

nope, gotta catch'em all
 

aztlan

Casual Client
Joined
Sep 14, 2013
Re: Multiple Backgrounds Mod

While putting updated downloads in the OP is handy, it's also nice to add a post saying you updated the OP with the new download so people who look for new posts will find your new download.
 

Zalord

Content Creator
Joined
Jun 12, 2013
Re: Zalord's Mods

Well look who has his own mod thread now. Things are looking good for zalord.
 

Zalord

Content Creator
Joined
Jun 12, 2013
Re: Zalord's Mods (Update June 19 Clean Codes)

AaRL said:
zalord said:
I make mods to add functionality or to fix issues with the game.

sby's Padawan?

He and ModGuy have been kind enough to answer any questions that I've sent their way. Big thanks to both of them for helping me out. The resources that sby provides at the bottom of his loader imports has been a huge help. LINK
 

aztlan

Casual Client
Joined
Sep 14, 2013
I like Clean Codes - thanks!

It doesn't add a feature but is a much better interface. I wonder if it works with Dialogue Actions (can DA use codes formatted this way...)
 

kjon

Potential Patron
Joined
Dec 21, 2013
Thank you for Clean Codes, it works perfect!

aztlan said:
I wonder if it works with Dialogue Actions (can DA use codes formatted this way...)

I'll give it a try, whish me luck 8)
 

Zalord

Content Creator
Joined
Jun 12, 2013
aztlan said:
I wonder if it works with Dialogue Actions (can DA use codes formatted this way...)
It shouldn't work. What are you looking for it to do? I've never used DialogueActions, but I just took a look at an example Dialogue and I didn't see anything wrong with it.
 

aztlan

Casual Client
Joined
Sep 14, 2013
I was wondering if you could just copy and paste it in for the da.charcode.load commands - it looks like not. I assume you can't have a carriage return internal to a line.
 

fighterfighter

Potential Patron
Joined
Jun 6, 2013
Just found your mods. I love that backgrounds mod, works like a charm.

Question, would that same thing be possible with hairs? Being able to cycle through custom hairs?
 

Zalord

Content Creator
Joined
Jun 12, 2013
Hey guys. Just checking in to say I'm still alive. Been super busy with a really big move and a new job. Most of my free time has been spent meeting new people and exploring the new city. As soon as I get properly settled in, I'll continue writing mods.
 

kjon

Potential Patron
Joined
Dec 21, 2013
zalord said:
Hey guys. Just checking in to say I'm still alive. Been super busy with a really big move and a new job. Most of my free time has been spent meeting new people and exploring the new city. As soon as I get properly settled in, I'll continue writing mods.

Do not worry, take your time, and keep the excellent work 8)
 

Zalord

Content Creator
Joined
Jun 12, 2013
Hey again,
Stopping in for a quick update. I still intend to get back to writing these mods, but I'm gonna wait until I get a new computer first, which is pretty low on my list. The laptop I use now is 6 years old and near the end of its life. Using it is a pain. I've been doing most of my internet browsing on my phone and tablet, neither of which are appropriate for writing these mods.

At the most conservative estimate, I can see myself back to working on this stuff in at most 3 months from now.
 

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.