Jump to content

Problem with hats and character scale


Recommended Posts

Hi, i'm new to the forum although i've been following for a while without posting.

So i wanted to create a character with a friend of mine, he would do the coding and i'm doing the art.

I followed this guide  http://forums.kleientertainment.com/topic/37002-easy-character-art-tutorial/?p=491446

It works just fine, and the texture layout is easier to work with than others i saw on the workshop (In my opinion) , but i have a big problem, when the character wears any hat that uses headbase_hat the head is invisible. I didn't make headbase_hat just a blank png, it has the textures. So i don't know what is the problem, here's a video https://www.youtube.com/watch?v=9QL7qzGfwbE&feature=youtu.be (GO TO 1:37) 

 

A smaller problem is that the character, by default was too short and small. So i added this line inst.Transform:SetScale(1.3, 1.3, 1.3) which makes him bigger but the hats get bigger as well. 

 

If anyone trying to help me needs the files i'm working with, i can upload them.

Thanks

Link to comment
Share on other sites

@Mkez,

 

All swap items (such as hats and weapons and armor actually literally get swapped into your character's build when equipped.  It's not shown in Spriter due to technical limitations, but in addition to all of the layers in the extended character template, there are additional layers called "swap_object" (and swap_hat, etc.) in the actual animation files.  When you equip an item the game replaces the blank image in that layer with the one from your swap_<whatever> build.  So if you apply a transform to the character's animation, equipped items get transformed as well, since at that point they're part of the animation.

 

If you need to increase the size of your character, you have to edit the sprites themselves to be bigger.

Link to comment
Share on other sites

@Mkez,

 

All swap items (such as hats and weapons and armor actually literally get swapped into your character's build when equipped.  It's not shown in Spriter due to technical limitations, but in addition to all of the layers in the extended character template, there are additional layers called "swap_object" (and swap_hat, etc.) in the actual animation files.  When you equip an item the game replaces the blank image in that layer with the one from your swap_<whatever> build.  So if you apply a transform to the character's animation, equipped items get transformed as well, since at that point they're part of the animation.

 

If you need to increase the size of your character, you have to edit the sprites themselves to be bigger.

So i've abadoned that method and ported the textures to Dleowolf's extended char method. While i don't have problems with the headbase_hat, i still have the character being too small. So i tried increasing the texture size by 150%, but nothing changed. So i tried 300% and still nothing. I'm going to try again and make sure i don't make any errors but i doubt it'll work. Also of course in spriter it becomes  a mess since the sprites had the old layout that is too small for the bigger sprites.

Link to comment
Share on other sites

@Mkez, you need to change the actual dimensions of the sprite image files, not the size within spriter-- since you are literally just swapping your sprites into the existing player animations, literally nothing done to the sprites within the spriter project will affect the in-game look the of character.  (Or rather, no transforms that you apply in Spriter will make it-- the only thing that matters is the layer names in spriter, and the actual image used in that layer on the first keyframe)

 

The x/y position, x/y scale, rotation, and any other animation-related attribute of each symbol is already baked into the player animations.  What you are doing is swapping the sprites in the default symbols with your own sprites.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...