Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 11 12 [13] 14 15 ... 21

Author Topic: Mod Base 0.95yy. Discontinued.  (Read 60651 times)

Shadowlord

  • Bay Watcher
    • View Profile

Quick feature request: The ability to make an MSECT default to unchecked instead of checked, e.g. [MSECT:Tilemod Flower quotes:DEFAULTOFF][FILE:flower_quotes_fixeyes][TILEMOD:flower_quotes]

Edit: Noticed a bug: When an OPT component is enabled, it disables *all* other components, not just other OPT components. Furthermore, as a result of this, when a mod is scanned and loaded, all components loaded prior to the last opt component will be disabled (or so it appears).

Edit #2: Slight problem with the tileset feature: It doesn't put the mod_bmpfilename.bmp file in data/art, so DF ends up with a completely black screen. Actually, I don't see the mod_bmpfilename.bmp file anywhere... Maybe it isn't writing it out at all.
« Last Edit: July 24, 2008, 02:09:50 pm by Shadowlord »
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

Yeah, now I noticed the oversight on my part - while usually it won't happen, but if a mod's saved order is such that the program tries to swap it with a mod outside of the mods array, it will crash. I'm thinking of better ways to solve the thing. Yours looks good, but I want to see if I can do better. ;)

Added the :OFF optional parameter, also fixed another oversight that disallowed having both MAIN and OPT as parameters.

Added the graphics mode switch to init editor and tileset mods.

About the tileset feature - you mean the "TILESET" fraction of a mod module, the tileset swapper screen, or the "TILEMOD" fraction of a mod module? The first two don't create a "mod_*.bmp", only the third does - the first two just copy the tileset as it is. I might have made an error with the first though, lemme check...  no, I see no error. In the tilemod case, you have to have your modded tileset image have the same name as the image you're altering through the mod. I've tried the thing several times and it worked for me.
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

About the tileset feature - you mean the "TILESET" fraction of a mod module, the tileset swapper screen, or the "TILEMOD" fraction of a mod module? The first two don't create a "mod_*.bmp", only the third does - the first two just copy the tileset as it is. I might have made an error with the first though, lemme check...  no, I see no error. In the tilemod case, you have to have your modded tileset image have the same name as the image you're altering through the mod. I've tried the thing several times and it worked for me.

That confuses me. I have a tileset bmp in my mod folder, and some optional tilemod bmps which could be applied to it. The instructions and what you've said here both seem to be saying that I need to name every tilemod bmp the exact same thing as the tileset bmp, which makes no sense at all. I figured I must have been misunderstanding the instructions, since it seemed to be rather impossible to do what it seemed to be saying that I should do, so I tried to do what seemed the most sensible thing instead, but it didn't work. (But you just said basically the same thing as the instructions, so now I'm even more confused)

Here's how it looks:
This is in the mod's .txt file:
Quote
[MSECT:Tileset][TILESET:SL_square_16x16]
[MSECT:Tilemod Green/brown trees][FILE:matgloss_sl_green_brown_trees][TILEMOD:green_brown_trees]
[MSECT:Tilemod Flower quotes][FILE:flower_quotes_fixeyes][TILEMOD:flower_quotes]
[MSECT:Tilemod Winter Trees][TILEMOD:wintertrees]

In the mod's folder, there exists SL_square_16x16.bmp, green_brown_trees.bmp, flower_quotes.bmp, and wintertrees.bmp. The tilemod bmps do have the pure blue background (RGB 0,0,255) except for the tiles which are to be replaced.

It did change the init.txt to say mod_SL_square_16x16.bmp when I had the tileset and a tilemod checked, but no such file was created anywhere on the computer (I had windows search all three partitions for it while I was off doing something else).

P.S. It didn't seem to restore the init.txt's font and stuff when I unchecked the tileset and tilemod and re-applied, although I kind of figured that might happen.
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

Hm. Yeah, I need to think of a way to have the thing discern files of that sort. I can probably add a check for a part of the filename after the last underscore, would that suffice?

addendum: Had no time to type longer, cellphone keyboard. :)

Basically, I can (probably) make it read files like "stuff_stuff_1.bmp" and "stuff_stuff_2.bmp" as one file "stuff_stuff.bmp", though there may be complications with simple files without additions, where "stuff_stuff.bmp" will be read as "stuff.bmp". Maybe a double underscore? Those are rarely present in filenames...
« Last Edit: July 27, 2008, 01:37:48 pm by Sean Mirrsen »
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

So the tilemod bmp filenames would then be something like SL_square_16x16_greenbrowntrees.bmp, SL_square_16x16_flowerquotes.bmp, and SL_square_16x16_wintertrees.bmp? That sounds fine to me.

(Why's that a requirement anyhow?)
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

I'd need to keep the filename to replace somewhere. So it's either a separate definition file, or a system like this.
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

I had figured that it would require the mod to also include an active tileset component, and that would be what would get replaced.
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

If you include your own tileset anyway, why bother with "mods"?

Anyway, I think I handled that issue, plus a handful of other ones.
The program will now attempt to create (and use) copies of init and speech files, rather than the originals.
The originals will be copied over at program start, if they weren't present before, so it's advised to install the thing over a clean DF copy.
I'll attempt to do a bit of testing here at work, and maybe release .94b when I get home.
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

To give the user the option of using particular art or not - a simple example would be the " symbol. Normally the " symbol is used for shrubs as well as quotes in text. Flying Mage made a nice flower icon for shrubs, but having it show up in text where " is supposed to be is kind of annoying.

So, I'd want to make the " symbol normally have the normal " art, but to give people the option of using the flower icon if they choose to do so, and the logical way to do that would be with a tilemod (and a file to remap the glow-in-the-dark-eyes, which I also did).
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

Hm. Alright.

I'm more or less content with testing results now, with some more additions squeezed in. Now, it's possible to have "main optional" components - that is, a set of "MAIN" components that can be selected one at a time, but turning off the last one will turn off the mod. It's also possible to have init mods as part of your mod, so you can change colors and stuff.

I've also made a few internal and interface changes regarding progress display when compiling mods.
This originated from my experiments with the Metamagic Weapons section of my MA+ mod. The new variant, called Metamagic Megaweapons, uses the Modbase conditional creation features. I don't know exactly how many weapons it creates, but the resulting raws file is 1.2Megabytes, for the weapons alone. Thankfully, I don't have to place them anywhere - they'll only come up for moods or drops from magic chests. During experimentation, I got a Freezing Mudstone Greatsword of Blizzards - that one was fun. I did get a Dull Dagger of Slicing too, though.
Well, the net result of all this was that Modbase suddenly had to spend some 10-20 seconds in complete limbo, eventually becoming "Not responding" while compiling mods. So I expanded the progressmeter (hitting an overflow error in the process), and added a scrolling ">> Working >>" sign that appears on the Activate button, to show that the process hasn't locked up.
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

About the tileset problems again:

I just tried:
1. Extract DF from zip file into a new folder
2. Extract ModBase into that new DF folder
3. Copy the mod I'm working on into the modbase folder. Nothing was copied into art or the init folder or anything like that.
4. Start ModBase, scan, disable the test mod, make sure the tileset component is enabled, and all the tilemod components are disabled.
5. !!! ACTIVATE !!!
6. Start the game. DF asks for fullscreen or windowed, select windowed.

I got a black screen. I went and checked the art folder and the init: ModBase did copy the font bmp correctly (SL_square_16x16.bmp), but it set the init file to use mod_SL_square_16x16.bmp, which it did not create.

I tried this with tilemod components in the mod, all disabled, and I tried removing the tilemod components from the mod to see if disabled tilemods were confusing ModBase, but it still set the init file to use mod_SL_square_16x16.bmp instead of SL_square_16x16.bmp.

(I tried this again because my tileset/mod is basically ready for release, except that I had been intending to have ModBase handle installing the tileset. So I had been hoping for the next version of ModBase to be released, or hoping that this version would turn out to be able to do it after all. The alternative, of course, is giving instructions for installing the tileset just like all the normal tilesets. :P )
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

I've been a little engulfed by various affairs (mostly concerning my relatives areound here, who seem to see laziness as a capital offence), so I wasn't able to do any specific stuff on the new release yet. I can put it together and upload it now, but odds are that without testing it'll be worse than the current one.

edit: hm, wow. Just now I looked at the relevant portion of the code for the n-ty-nth time, and only now I noticed that I have indeed been keeping the "mod_" addition to the filename, only I couldn't see it because it was in one string with the [FONT: line, not separated as it is in file copying lines. Fixed now. I'll pack it up and put it up on DFFD, but I won't update the front page yet, I'm too tired from all the work today (dacha... I never want to hear the word again... :)).
« Last Edit: July 31, 2008, 04:03:52 pm by Sean Mirrsen »
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Sean Mirrsen

  • Bay Watcher
  • Bearer of the Psionic Flame
    • View Profile

Alright, bump. 0.94b (dubbed "bug fest galore") is released, virtually without testing of the modified features.

I recommend either installing over a clean DF install, or making sure your init settings suit you before running this new Modbase, because it will make a copy of your current init.txt and speech files.

The list of changes is probably this:
Added :OFF parameter to MSECT module descriptors - makes module inactive by default.
Added INIT section to MSECT module descriptors - allows adding a text file modifying init settings.
Allowed the program to read tileset files differing by text after a double underscore as one file.
Modified progress meter and button visuals during mod compilation.

I wanted to make some experiments with adding .jpg, .gif and .png tileset compatibility (technically the language allows that), but I didn't have any time. I did punch my keyboard hard enough for at least half of the required creature tags to magically appear in the mod constructor definition files though...

Also, Martial Arts mod updated. Look for it in the MCM pack. Added some new megabeasts, tuned existing ones (to the point that I consistently run worldgen past 200 on mediums), and added the awe-inspiring MegaMagicWeapons mod, that can replace the normal Magic Weapons. Take note, the MMW will take a while to compile, especially if you put weapon mods of your own before MA+.
Logged
Multiworld Madness Archive:
Game One, Discontinued at World 3.
Game Two, Discontinued at World 1.

"Europe has to grow out of the mindset that Europe's problems are the world's problems, but the world's problems are not Europe's problems."
- Subrahmanyam Jaishankar, Minister of External Affairs, India

Shadowlord

  • Bay Watcher
    • View Profile

Okay, the first bug I ran into was:
It's throwing an overflow exception while trying to activate a mod with an enabled tileset component (it happens on the modbase test mod, so it should be pretty easy for you to reproduce).

System.OverflowException: Arithmetic operation resulted in an overflow.
   at ModBase.Form1.CompileMods_Click(Object sender, EventArgs e)
   at System.Windows.Forms.Control.OnClick(EventArgs e)
   (And so on.)
Logged
<Dakkan> There are human laws, and then there are laws of physics. I don't bike in the city because of the second.
Dwarf Fortress Map Archive

Earthquake Damage

  • Bay Watcher
    • View Profile

While !REPLACE says "add this only if this object already exists," I don't see any way to flag an object with "add this only if this object doesn't already exist."

Such a thing might be useful if, say, you have two different plant mods that add a VINE_TOMATO.  The results might get pretty strange if two tomatoes with wildly different definitions both get installed.


While I'm here, I'd like to request a means to install creature graphics via Modbase.  Also, this is another situation where "add this only if this object doesn't already exist" would be useful.  For example, you may be installing two different graphics sets for dwarves, but one is more complete than the other (and you don't mind mixing styles).
« Last Edit: July 31, 2008, 09:39:08 pm by Earthquake Damage »
Logged
Pages: 1 ... 11 12 [13] 14 15 ... 21