Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Poll

Which secret containing book should we steal first?

Creatures Uncovered (Concerns the secrets of the beast warrior)
- 5 (6.4%)
Misconceptions About The Dragonlord (Concerns the secrets of dragons)
- 10 (12.8%)
Foundations of Blizzards (Concerns the secrets of wind and air as magical weapons)
- 6 (7.7%)
The Meaning of Dragonfire (Concerns the secrets of dragons)
- 5 (6.4%)
Book of Coagulation (Concerns the secrets of legendary cheese making)
- 42 (53.8%)
Look for more books, I want a different secret
- 1 (1.3%)
Let's just steal a slab and hope for the best
- 9 (11.5%)

Total Members Voted: 78


Pages: 1 ... 3 4 [5] 6 7 ... 100

Author Topic: The Resurgence of Modded Hell (Back, Still Broken, Now With Giant Butterflies)  (Read 301232 times)

scourge728

  • Bay Watcher
    • View Profile

interesting....

EDIT: Forgot to mention, I've got some mods sitting around somewhere....

bloop_bleep

  • Bay Watcher
    • View Profile

Hrmm... script seems to not be working. I fixed up the first few basic bugs, but now it just crashes the game whenever the baby is supposed to be born.

Perhaps it's because I'm testing in arena mode, which might not have been designed to handle pregnancies?
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

MottledPetrel

  • Bay Watcher
  • If only I knew what was going on
    • View Profile

You could try setting the pregnancy to only a few days and bringing a few in fort mode, that might help see if it's the arena's fault. And any mods help here scourge, just try to tell us what they do first.
Logged

bloop_bleep

  • Bay Watcher
    • View Profile

Nah, it wasn't that, it still crashed in fort mode.

Though, I think I might've found the problem, which has to do with pregnancy genes. I searched for DFHack scripts that involved pregnancy in some way and came across catsplosion.lua, and it looks like there's a specific process you have to use to obtain pregnancy genes, so  you can't just copy them from the parent directly.
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

MottledPetrel

  • Bay Watcher
  • If only I knew what was going on
    • View Profile

I'm trying out all the Zelda civs individually, hopefully at least a few work. If they all don't work for whatever reason I'm just going to give their items and reactions to other working civs.

Edit: Gonna list them as they show up in the files
0_Foes: Works
1_Hylians: Works
1b_Temples: Works
1c_Towns: Works
2_Kokiri: Works
2b_Winds: Works
3_Goron: Potentially working? (gave me a lot more problems than the others, but doesn't straight up crash it)
3b_Peaks: Mostly working (little bit of world gen trouble with world gen)
4_Zora: Works
4b_Earth:
5_Skeikah:
5b_Dust:
6_Gerudo:
6b_Sea:
7_Twili:
7b_Twili:
8_Zuna:
8_Zuna:

Edit from the furture: This mod doesn't work in 44.02, so it doesn't really matter.
« Last Edit: December 09, 2017, 09:46:34 pm by MottledPetrel »
Logged

bloop_bleep

  • Bay Watcher
    • View Profile

K, so the script is working now. Here is the code.

Code: [Select]
local LAWNMOWER_NAME = 'LAWNMOWER'
local PREGNANCY_LENGTH = ?????
local PREGNANCY_CHANCE = ?????
local IMPREGNATION_REPEAT = 100

local repeat_util = require 'repeat-util'

local rng = dfhack.random.new()

local function select_caste(race)
    local raws = df.global.world.raws.creatures.all[race]
    local s = 0

    for i, chance in ipairs(raws.pop_ratio) do
        s = s + chance
    end

    local n = rng:random(s-1)

    for i, chance in ipairs(raws.pop_ratio) do
        if n < chance then
            return i
        end
        n = n - chance
    end
end

local function impregnate_unit(unit)
    unit.pregnancy_timer = PREGNANCY_LENGTH
    unit.pregnancy_caste = select_caste(unit.race)
    local genes = df.unit_genes:new()
    genes.appearance:assign(unit.appearance.genes.appearance)
    genes.colors:assign(unit.appearance.genes.colors)
    unit.pregnancy_genes = genes
    unit.pregnancy_spouse = unit.id
end

local function impregnate_lawnmowers()
    local number_viable = 0
    local number_impregnated = 0
    for i, unit in ipairs(df.global.world.units.active) do
        if df.global.world.raws.creatures.all[unit.race].creature_id == LAWNMOWER_NAME then
            if unit.pregnancy_timer == 0 then
                number_viable = number_viable + 1
                if rng:drandom() < PREGNANCY_CHANCE then
                    number_impregnated = number_impregnated + 1
                    impregnate_unit(unit)
                end
            end
        end
    end
    --print("Number viable: " .. number_viable)
    --print("Number impregnated: " .. number_impregnated)
end

repeat_util.scheduleEvery('impregnate_lawnmowers()', IMPREGNATION_REPEAT, 'ticks', impregnate_lawnmowers)
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

Paxiecrunchle

  • Bay Watcher
  • I'm just here, because actually I don't know*shrug
    • View Profile

Wow, I would never have thought about mating lawnmowers before I read this thread, now those horrifying images will never leave me.

Urlance Woolsbane

  • Bay Watcher
    • View Profile

If you want to make this even more chaotic, I'll happily upload a modified version of the executable that will allow you to modify procedurally-generated creatures.
Logged
"Hey papa, your dandruff is melting my skin. Is that normal?"
"SKREEEONK!!!"
"Yes, daddy."

bloop_bleep

  • Bay Watcher
    • View Profile

Okay, now we just have to figure out the parameters for my script. Tell me how long you would want pregnancies to last and by how many percent you would like the lawnmower population to grow in a year and I will compute the necessary values.
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

Enemy post

  • Bay Watcher
  • Modder/GM
    • View Profile

I'm looking forward to this fort of communist turtle lawnmower ranchers.
Logged
My mods and forum games.
Enemy post has claimed the title of Dragonsong the Harmonic of Melodious Exaltion!

pikachu17

  • Bay Watcher
  • PADORU PADORU
    • View Profile

I just need to read the above post to know this will awesome/funny. Post to watch.
Logged
Sigtext!
dwarf 4tress from scratch
The Pikachu revolution!
Thank you NatureGirl19999 for the avatar switcher at http://signavatar.com

A warforged bard named Gender appears and says"Hello. I am a social construct."

MottledPetrel

  • Bay Watcher
  • If only I knew what was going on
    • View Profile

Okay, so for the pregnancy time I'd say like two seasons or a season and a half, somewhere around there. And unless we want lawnmower army I would say keep the growth to around 50% to 70%. But since the consensus is that we are now a fort of lawnmower ranchers I'm not sure about that, we'll see what everyone says.

Scourge I'm going to get to implementing your mod, but not tonight.

Urlance Woolsbane I would love to screw up the world even more by messing up the procedurally generated monsters. You're probably going to have to explain how to do it, but the person to make the best monster gets to be baron. If that's how it works, but we'll figure that out.

And I'm glad to see that we've got a lot of support for the metal communist turtle fort of lawnmower ranching. We should probably start coming up with a real dwarf fortress name, but we'll get there. I would have liked a few more names for Koopas so instead of "UristMcKoopa was mauled to death by a lawnmower" we could have "Our noble Koopa, leader of the armed Koopa forces, Dave, has fallen at the hands of the capitalist lawnmower. Valiantly did he defend his home and family, Davina and kids David Daviner and Dave Jr., from the enemy Santa empire. Long will our noble bard, Davidarius, sing of his name to the glorious communist Koopa empire." but oh well, hopefully we'll get there. Or I'll just start accepting random names for our citizens.
Logged

Enemy post

  • Bay Watcher
  • Modder/GM
    • View Profile

I'll take a Koopa. Any job is fine, I'd prefer male.
Logged
My mods and forum games.
Enemy post has claimed the title of Dragonsong the Harmonic of Melodious Exaltion!

bloop_bleep

  • Bay Watcher
    • View Profile

Well, I would do that, but I find it inside my conscience to inform you that if the growth was set to 50% that the lawnmower population would grow 100 times bigger in a bit more than 11 years.  :P I recommend a growth rate of 5% per year, since then your population would grow as much only after about 94 years.
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.
Pages: 1 ... 3 4 [5] 6 7 ... 100