Jump to content

Recommended Posts

Just now, Pinkamena11FazP said:

Here's the zip file I tried to make for my character: It is refusing to show my character and not letting my custom text show... Nor my custom music I added... If someone could please fix it I would be very happy!

If you go to the Extended Character Template tutorial, there should be a section about creating new animation (anim) builds. You need to make sure that your builds are named correctly during this process.

22 minutes ago, bizziboi said:

=


function LocoMotor:WalkForward(direct)
    self.isrunning = false
    if direct then self.wantstomoveforward = true end
    self.inst.Physics:SetMotorVel(self:GetWalkSpeed(),0,0)
    self:StartUpdatingInternal()
end

I mean, I just did a search, I haven't verified if there's a path leading there, but I think with controller or directional keys this gets called?

Ah, of course! I only play with the mouse, and when I click it always runs. I checked, and it always uses the run-speed instead of the walking-speed. But I can see that that function you posted is called by the common states "walk_start" and "walk", so they're probably used for the players SOMEwhere. Other than that, only the blowinwind component and almost all the creature stategraphs use it, but not the player prefabs. I guess they're just using the common states mentioned before.

EDIT: Well, I was wrong. Several prefabs directly set the runspeed variable. I don't know how I missed that. Must have messed up my search. I will amend my previous post as to not confuse people finding this later.

Edited by Ultroman
20 minutes ago, Pinkamena11FazP said:

btw it kept changing to: "Wilson" and "The great papyrus" because I used some lines from that but didn't need my character with a beard

What kept changing to Wilson and "The great papyrus"?

Just now, Pinkamena11FazP said:

Rats I crashed. 

Aw...jpg

I'm assuming you have new code, in which case I would have to see your new sweetie.lua file. But before you post that, make sure that it says TUNING.WILLOW_WALK_SPEED

Edited by Ultroman
Just now, Pinkamena11FazP said:

Oh it was a little glitchy and my text files had: "Wilson" and "thegreatpapyrus" names on it and I tried to change it to Willow and I crashed. But when I do Wilson it works but I can't see my character.

If you mean what I think you mean, then I have no idea what you're trying to do. Please post a new zip of your mod as it is now with the error. I have to see what it is you're doing.

You have not created you animation builds correctly. Instead of building them, you've zipped an scml file into one of them, and some folders and stuff into the other one.

This is the text from the Extended Character Template tutorial.

On 18.12.2014 at 10:31 AM, Dragon Wolf Leo said:

Go to the exported folder. There are two or three folders, esctemplate, esctemplate_cleared, and if you're modding DST, ghost_esctemplate_build. For now, you can ignore esctemplate_cleared (if you want) since that's only there for reference, but you should rename the other two to your character's name, and also the .scml files inside them.

Finally, let's go to the anim folder.
You'll see one or two .zip files, esctemplate.zip, and if you're modding DST, ghost_esctemplate_build.zip. These aren't quite easy to rename, since it requires also changing the name within build.bin to work. But you don't need to. The contents of the exported folder will compile into this folder, so you can just delete these. New ones will appear, already renamed to your character's name.

Now our character should be fully renamed. It's a good idea to test the mod at this point to see if we've done this correctly.

Compiling
Compiling the mod will convert your .png files to .tex and .xml files, and your .scml to .zip files in the anim folder. This is usually done automatically, since the autocompiler launches whenever you start Don't Starve, as long as you have the mod tools installed.

Alternatively you can force-run the compiler by running Steam\steamapps\common\Don't Starve Mod Tools\mod_tools\autocompiler.exe.

If you need it, there's another way to compile the Spriter project by using scml.exe in the mod_tools folder directly. Start your Command Prompt, and drag the path of scml.exe, the path to your .scml file, and the path to your mod folder.

It should look something like this:

XS8NCCg.gif?1

 

Png files that aren't in the exported folder can be converted in a similar way, but using png.exe instead.

If everything ran smoothly, we can work on the art next.

Edited by Ultroman

Looking at the last few messages (cause ill assume the previous page is solved) there's no variable called "WILLOW_WALK_ETC" or "WILLOW_HUNGER_RATE", so it crashes cause the game doesn't know what it is, so replace the sweetie.lua (the character file) with the one posted. There was also some code called function LocoMotor:WalkForward(direct) that's actually in the game and isn't necessary (or even in the right place if you really want to change it but that's advanced coding practice).

sweetie.lua

That's not what mine says when I do the same thing. I took the most recent sweetie.zip you uploaded, deleted the zips in the anim folder, started DST, the auto compiler started running, and produced this error:

ERROR: Missing image 'ghost_hairpigtails/ghost_hairpigtails-0.png' referenced by 'ghost_esctemplate_build.scml'.

ERROR: Missing image 'hair/hair-0.png' referenced by 'sweetie.scml'.

You can find the log for the auto compiler here: <SteamLibrary>\steamapps\common\temp

You haven't included your anim files in the assets for the player prefab.

Change this:

local assets = {
    Asset("SCRIPT", "scripts/prefabs/player_common.lua"),
}

to this (I also removed the SCRIPT reference, since you already use "require" to inject it into your prefab):

local assets = {
	Asset("ANIM", "anim/pink.zip" ),
	Asset("ANIM", "anim/ghost_pink_build.zip" ),
}

I've also seen a lot of character mods have all these extra standard animation included. I don't know if they're needed, but if you're experiencing animation problems with the code above, try this:

local assets = {
	Asset("ANIM", "anim/player_basic.zip" ),
	Asset("ANIM", "anim/player_idles_shiver.zip" ),
	Asset("ANIM", "anim/player_mime.zip"), 
	Asset("ANIM", "anim/player_actions.zip" ),
	Asset("ANIM", "anim/player_actions_axe.zip" ),
	Asset("ANIM", "anim/player_actions_pickaxe.zip" ),
	Asset("ANIM", "anim/player_actions_shovel.zip" ),
	Asset("ANIM", "anim/player_actions_blowdart.zip" ),
	Asset("ANIM", "anim/player_actions_eat.zip" ),
	Asset("ANIM", "anim/player_actions_item.zip" ),
	Asset("ANIM", "anim/player_actions_uniqueitem.zip" ),
	Asset("ANIM", "anim/player_actions_bugnet.zip" ),
	Asset("ANIM", "anim/player_actions_fishing.zip" ),
	Asset("ANIM", "anim/player_actions_boomerang.zip" ),
	Asset("ANIM", "anim/player_bush_hat.zip" ),
	Asset("ANIM", "anim/player_attacks.zip" ),
	Asset("ANIM", "anim/player_idles.zip" ),
	Asset("ANIM", "anim/player_rebirth.zip" ),
	Asset("ANIM", "anim/player_jump.zip" ),
	Asset("ANIM", "anim/player_amulet_resurrect.zip" ),
	Asset("ANIM", "anim/player_teleport.zip" ),
	Asset("ANIM", "anim/wilson_fx.zip" ),
	Asset("ANIM", "anim/player_one_man_band.zip" ),
	Asset("ANIM", "anim/shadow_hands.zip" ),
	Asset("ANIM", "anim/pink.zip" ),
	Asset("ANIM", "anim/ghost_pink_build.zip" ),
}

 

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...