Wayward
Wayward Mods
Make a new creature! Make a new item! Make a troposphere! Your imagination is the only limit with Wayward Mods on Steam Workshop.
了解更多
Horth 2016 年 9 月 7 日 上午 5:02
Modding - Furnaces
Is there a way to Mod the game so that camp fires and anvils/furnaces burn longer? What tools are used for such mods, just Notepad / XML Editor?
< >
正在显示第 1 - 5 条,共 5 条留言
Drathy  [开发者] 10 2016 年 9 月 7 日 上午 8:34 
You can already do this in the game by stoking the fire, unless you just mean by default. This would be pretty easy to mod.

There's a modding guide located here: https://github.com/WaywardGame/mod-reference

Examples mods: https://github.com/WaywardGame
Horth 2016 年 9 月 8 日 上午 8:17 
I am missing a tiny bit of info:

===============
private newFurnace: number;

class Mod extends Mods.Mod {
public onInitialize(saveDataGlobal: any): any {
}

public onLoad(saveData: any): void {
console.log("New Furnace Mod is active!");
this.newFurnace = this.addMessage("newFurnace", "New Furnace Mod is active!");
}

public onGameStart(isLoadingSave: boolean, playedCount: number): void {
ui.displayMessage(this.newFurnace, MessageType.Good);
Item.defines[ItemType.Furnace].X *= 10;
}

public onUnload(): void {
}

public onSave(): any {
}
}


What do I replace the X with in the line?

Item.defines[ItemType.Furnace].X *= 10;

Thank you for all the kind and informative responses to this and my many other questions posted on this forum.

Drathy  [开发者] 10 2016 年 9 月 8 日 上午 8:35 
Actually, what you would be looking for is to mod the Doodad, here's the full properties of the lit furnance to give you an idea:

defines[DoodadType.LitFurnace] = { decayMax: 8, blockDig: true, fire: true, lightSource: 1, blockMove: true, revert: DoodadType.Furnace, animated: true, repairable: true, particles: [104, 100, 100] };

You'll want to change the decayMax, that is the default value. So something like defines[DoodadType.LitFurnace].decayMax *= 10;
最后由 Drathy 编辑于; 2016 年 9 月 8 日 上午 8:35
Horth 2016 年 9 月 8 日 上午 10:44 
Excellent info. Thank you. Now, what I didn't find (yet) on GitHub is how to make the 10 a value that I can set via options for the Mod, or how to even hook in user options for Mods. The objective is that you could play with the mod and set the multiplier value according to a slider with min value of 1 and max value of 10 (or other desired max controlled by the Mod).

Some other questions:

Also, are campfires also a DoodadType.LitCampfire ?

What does the 8 in maxDecay represent - 8 game hours?

Does the default LitFurnace having, 8 maxDecay get ignited at decay = 1, and decay is increased by X (depends in the fuel) up to a max of 8 when fuel is added?

When decay = 0, it reverts to DoodadType.Furnace = fire goes out?

When you mouse over the Furnace to see its status, are the messages determined by percentage of decay (is it even called decay) versus maxDecay?

Thank you again.
Drathy  [开发者] 10 2016 年 9 月 8 日 下午 4:42 
Typing "DoodadType." in VSCode (or supported editors) should give you a listing of all the doodads. LitCampfire is one, yep!

Time currently ticks in intervals of 20 turns. So, that 8 is 8x20 = 160 turns.

Each item has different stoke fire values which adds decay directly to that counter. Coal for example has a stoke fire value of 10, so adding it would add 10x20 turns to it's length.

When the counter goes down to 0, then yes, it unlights.

Yep, you are correct.
< >
正在显示第 1 - 5 条,共 5 条留言
每页显示数: 1530 50