Forum Replies Created
-
AuthorPosts
-
MyrkMember
I can’t edit the post again, so I’ll add the redacted parts here:
player.dexterity is for stamina, starvation for hunger and dehydration for thirst. strength also affects carry weight.
Here’s version one of the lazy button, as well as the Bark button:
$("#optionswindow").on("click", '#instantMiracle', function () { player.health = player.strength; player.stamina = player.dexterity; player.hunger = player.starvation; player.thirst = player.dehydration; }); //Sets respective stat to its max. $("#optionswindow").append('<button type="button" id="instantMiracle">I Want To Live!</button>');
$("#optionswindow").append('<button type="button" id="getBark">Bark</button>'); $("#optionswindow").on("click", '#getBark', function () { itemGet({ type: "treebark", quality: "Random" }, 'silent'); });
I must apologize; I proposed these changes to the mod without James’ or Andy’s permission beforehand. I will ask before I propose any more changes from now on.
MyrkMemberI went skulking through the console and found the remaining total-stat variables.
[Redacted]Here’s my
lazytest button[Redacted]
On a related note: undefined/NaN stat values are very bad. For health it’s a 1-hit-kill, for Stamina you can only spin on the spot, and for hunger and thirst the value drops to -1 when the respective stat updates.
I also noticed two Get String buttons/functions in the version on the mods page, both of which ended up spawning six string instead of one (for the first button) and five (for the second), so
I tweaked the first String button to give tree bark:[Redacted]
My apologies if there are errors; I’m new to both Javascript and Wayward.
-
AuthorPosts