No video

Godot - 2D Character Customization with Composite Sprites

  Рет қаралды 70,443

Arkeve

Arkeve

Күн бұрын

Пікірлер: 122
@Arkeve
@Arkeve 4 жыл бұрын
Hey y'all! Also check out this video about attaching and animating weapons: kzbin.info/www/bejne/fYG8c4GajtqGepo Let me know what you think!
@galacticquasar9944
@galacticquasar9944 3 жыл бұрын
Hey, how would I make certain sprites not play if they're invisible? I'm guessing I'd need a global script but I'm having trouble with it, so hard to understand.
@betterteen
@betterteen 3 жыл бұрын
Can you put the download link for the font you are using!?!?!!
@MB_Arssin
@MB_Arssin Жыл бұрын
Guys if you're following tutorial and having in 2023 problem with “ invalid get index ‘body_spritesheet’ (on base: ‘GDScript’) “ at function _ready in Player script. You can try to create script in CompositeSprites (Player node) and past there preloads, then instead of using const const/var with composite_sprites just make bodySprite.texture = $CompositeSprites.body_spritesheet[0] and same for others -> worked for me.
@brandonstone2754
@brandonstone2754 Жыл бұрын
You can also make it a singleton
@johnslack9623
@johnslack9623 10 ай бұрын
@@brandonstone2754 You are right, but I generally feel pretty gross not having scripts associated with nodes and referencing those scripts. I think @MB_Arssin has the right of it.
@fyls3166
@fyls3166 Ай бұрын
Thank you very much for this
@Jormungus
@Jormungus Жыл бұрын
Just wanted to point out to anyone using Godot 4.0 that the onready keyword is now @onready in 4.0. If your getting identifier errors this is probably why.
@zephyrias
@zephyrias 6 ай бұрын
You can also hold ctrl or command when grabbing a node in the tree into the script to drop the whole @onready line in a simple click. 👏
@zerohero7457
@zerohero7457 3 жыл бұрын
This is one of the best tutorial that provide of what i need for my project, i look hard in youtube for finding this kind of tutorial for godot but no luck, also the tutorial is easy to follow and very understandable, im sure giving more time on designing the thumbnail will increase the views greatly.
@mesolagic
@mesolagic 4 жыл бұрын
This was very helpful man thank you! Was able to use this logic to script a clothing randomizer for procedural generated NPCs.
@Arkeve
@Arkeve 4 жыл бұрын
Glad I was able to help!!
@arthurocchiutto4686
@arthurocchiutto4686 3 жыл бұрын
please advise if u will show the process, Im searching info to make a proc generated items
@foreveraverage
@foreveraverage 2 жыл бұрын
Amazing tutorial, really helped me a lot. A small tip for everyone watching, if you put the compositedsprites into a viewcontainer->viewport. You can apply a material to the rendered end result instead on each sprite separate, which is probably going to give you the effects you want to. A character outline is a very common example (you can also put the character itself in a viewport of course but I prefer keeping the viewport inside your character as it allows you to keep al the rendering complexity inside the player script)
@violetevans5214
@violetevans5214 2 жыл бұрын
this was exactly what i was looking for, theres literally no other video that was as clear and perfect for what i wanna do as this- even down to using aseprite omg i love you
@PDD555
@PDD555 Жыл бұрын
You can't describe my relief, I've been looking for a tutorial/guide on how to implement these things and I swear I've been looking everywhere without luck. Thanks for the video
@heneagedundas
@heneagedundas Ай бұрын
Nice. This helps in a current project. Now I just have to work out how best to change collision shapes and some other features when the sprite is changed.
@arithmetic1938
@arithmetic1938 4 жыл бұрын
Looks really good.
@MrNybbles
@MrNybbles 4 жыл бұрын
@0:23 I think this was unintended, but the sudden switch from beautiful pixel art to 1990's 3D rendering made me laugh when the "Select skin colour and gender" graphic popped up. Was not expecting such a switch. I'm not sure what the game-play will be like, but hopefully I'll be able to see it in a future video.
@Arkeve
@Arkeve 4 жыл бұрын
Haha you are right! It is pretty jarring. I plan to release some gameplay videos soon!
@626070
@626070 3 жыл бұрын
It seems you do not have the recognition you deserve, I'll watch this video a lot to try to help you out as much as you helpd me. Thank you!
@ishechinyoka3858
@ishechinyoka3858 4 жыл бұрын
Holy 😳 u gained a new subscriber dude ur talented
@Snafuey
@Snafuey 3 жыл бұрын
Thanks for making these vids! Keep up the good work.
@MoogieSRO
@MoogieSRO 3 жыл бұрын
I know this probably isn't the place for it, but for your game, you might want to learn how to do sub-pixel sprite animations, as the one thing I immediately noticed when I started watching this video is how 'extreme' the breathing animation feels, and I think you could make that look a lot softer and more natural if you were to do some sub-pixel painting on it. Just a suggestion, your sprites already look good, but it would be a real boost to the general quality. Thanks for the video!
@_Lexusttv
@_Lexusttv 3 жыл бұрын
Thanks for the tutorials, cant wat to check the devlogs. You earned the sub!
@RichardCalder67
@RichardCalder67 2 ай бұрын
This is fantastic, thanks. Just curious (I am new to Godot) how do you handle the animations with a custom character like that? The sprite set I am using has different sprites for all the pieces like you have, but it also has it for tons of actions, axe, pickaxe, hoe, sword, etc. I can figure out how to apply the right sprites easily enough, but how do you handle the actual animation player and animation tree? Since the animation player asks for specific sprite locations for each thing.
@Chronofrost001
@Chronofrost001 Жыл бұрын
Thank you, because of this video I was inspired to design something similar for a Godot Game Jam I will be doing soon.
@hotboxbuddy
@hotboxbuddy 3 жыл бұрын
Hot tutorial, Dad. Very straight forward and easy to understand! I subbed
@rifamuhammadm30
@rifamuhammadm30 4 жыл бұрын
great work man !!! thanks for making tutorial for this, it's really help me learning godot
@Player-kl3ci
@Player-kl3ci 4 жыл бұрын
Thanks sir, is what I need this information. It really helps to me.
@Arkeve
@Arkeve 4 жыл бұрын
Glad I could help!!
@TenderEnders
@TenderEnders 4 жыл бұрын
Looks phenominal! I'm very new to Godot and trying to figure out how to make one of these, and this helps my 0 code knowledge brain. Thanks man!
@Arkeve
@Arkeve 4 жыл бұрын
Glad I could help!
@Anonymousanimator234
@Anonymousanimator234 4 жыл бұрын
Thanks a lot , you have helped me complet my game.
@chaokai3606
@chaokai3606 2 жыл бұрын
Hi is this tutorial outdated? Because at around 5:50 once i run the player scene i get the error "Invalid get index 'body_spritesheet' (on base: 'GDScript')." Anyone able to help me out with this? I'm pretty new to godot and coding any explanation would also be apreciated ;)
@earthsdefect1747
@earthsdefect1747 2 жыл бұрын
This is awesome. Thank you!
@asriel6485
@asriel6485 6 ай бұрын
Hi, i don't know if is there anyone still here but i have some trouble about button if "curr_hair = (curr_hair + 1)% composite_sprites.hairM_spritesheet.size()" is next hair types so i use "curr_hair = (curr_hair - 1)% composite_sprites.hairM_spritesheet.size()" for previous hair but it crash when curr_hair = 0 and i keep press prev button , is there anyway to fix it ?
@mattdavis3036
@mattdavis3036 4 жыл бұрын
Thank you. Inspiring, I'm going to try this.
@Arkeve
@Arkeve 4 жыл бұрын
Let me know how it goes!
@mattdavis3036
@mattdavis3036 4 жыл бұрын
​@@Arkeve I did it, works great! Now to figure out how to use generated sprites for npcs and save one for the main character (and make sure no npcs look exactly like the main character and stuff.) I'm really happy about this. Thanks!
@kegypie9901
@kegypie9901 3 ай бұрын
great tutorial, thank you!
@saulnores3477
@saulnores3477 3 жыл бұрын
Great tutorial. Do you have one for writing the name like in 0:03 that you type John?
@philipbooker8511
@philipbooker8511 4 жыл бұрын
Hey Arkeve! This Tutorial is great! It's been a godsend for my project. One thing I am curious about is how to animate all of these disparate sprites. Im finding that animationplayer can only play one sprite sheet at a time. I see that you have gotten this to work in your actual project. How did you do it?
@philipbooker8511
@philipbooker8511 4 жыл бұрын
Never Mind! You show it in the next episode. Even Godot Documentation doesnt have this feature listed. Thank you a million!!!!!
@Arkeve
@Arkeve 4 жыл бұрын
Glad I could help! Good luck on your project!! :D
@adamwebster1652
@adamwebster1652 Жыл бұрын
There's more episodes? Well, crap, this has made my weekend, thanks. Glad I saw these comments. I'm going to enjoy this
@jmouro1963
@jmouro1963 Жыл бұрын
Hi Arkeve. I love your video, how do I use the character with the hair and clothes after I choose in the game? do you have any coding that explain that part?
@Janosoft
@Janosoft 3 ай бұрын
Awesome!!!
@regoso8580
@regoso8580 4 жыл бұрын
hell ya, thank you for this!
@Arkeve
@Arkeve 4 жыл бұрын
No problem!!
@FillanEngram
@FillanEngram 4 ай бұрын
Can you do a video on how to animate a custom character?
@nikondrat3875
@nikondrat3875 3 жыл бұрын
Thank you. You helped me!
@syweb2
@syweb2 9 күн бұрын
8:50 How did you swap words only within the selected area?
@junpoeco4851
@junpoeco4851 2 жыл бұрын
I’ve followed your video to 5:57 and got “ invalid get index ‘body_spritesheet’ (on base: ‘GDScript’) “ at function _ready in Player script. I don’t know what to do with it 🥺. Thank you for the good tutorial though, It’s easy to follow but I don’t know why I got an error.
@MrAnimefrank
@MrAnimefrank 2 жыл бұрын
Same
@FirmFoundation
@FirmFoundation 2 жыл бұрын
Nice, Thanks
@CosmicKingEvol
@CosmicKingEvol 6 ай бұрын
I am struggling with this. How do I keep the sprites I selected in the next room? How do I make my created sprites global? When I use this and go to the next room, it is invisible.
@astronuggie
@astronuggie 3 жыл бұрын
I wish there was something like this for unity :( This is exactly what I need
@BOT-yh1jl
@BOT-yh1jl 3 жыл бұрын
We are 2
@haraldbackfisch1981
@haraldbackfisch1981 Жыл бұрын
there is, i can share if you are still looking. if not sry for necroing lol
@bordercolliestudios984
@bordercolliestudios984 4 жыл бұрын
Hello! This video is amazing! Can you perhaps make a separate video on saving the customized skin and how to work this skin as a player? I'm quite new to both Godot and coding. Doesn't only kinematicbody work as a player? (heard something like that in one of the videos I watched about Godot) Thank you!
@Arkeve
@Arkeve 4 жыл бұрын
Yeah all you would have to do is change the type of the Player node to be kinematic body. And keep the Sprites node as a child and should work the same way.
@bordercolliestudios984
@bordercolliestudios984 4 жыл бұрын
Thank you so much!!!!!
@doogl3661
@doogl3661 3 жыл бұрын
@@bordercolliestudios984 Hii Idk if the actual guy who made this will reply but what did you do to implement the character into another scene? I don't exactly understand his explanation. Thanks!
@SKtheMage
@SKtheMage 4 жыл бұрын
What Sprite maker do you use? also can you also do a tutorial for using the characters sprite in game or moving?
@Arkeve
@Arkeve 4 жыл бұрын
I use a pixel editing program called aseprite to make sprites. Check out my other tutorial about equipping and animating weapons to see how to make sprites move.
@SKtheMage
@SKtheMage 4 жыл бұрын
Thanks!
@EnormiE
@EnormiE Жыл бұрын
Well, it's great
@done1338
@done1338 3 ай бұрын
how much time did this take you to make?
@IustinNitza
@IustinNitza 4 жыл бұрын
Thx for this video
@funkycowsx2
@funkycowsx2 Жыл бұрын
Cool.
@ropepores4688
@ropepores4688 Жыл бұрын
Thank you!!!!!!
@Lucas-mp5dw
@Lucas-mp5dw 4 жыл бұрын
so you keep all of the sprites in different animators and run then in the same frame or there is an way to compose them together in one animator?
@Arkeve
@Arkeve 4 жыл бұрын
You can animate multiple sprites within one AnimationPlayer, you just change the frames for all the sprites within the player
@ryancraven6720
@ryancraven6720 3 жыл бұрын
So I was trying to implement this but ran into an issue. Basically when I made a second button to go back a sprite, the size() wraparound didn't work. It works fine when adding, but once I hit zero and try to subtract 1 it quits out on me. On_button_pressed current_hair = (current_hair - 1) % composite_sprites.Hair_spritesheet.size() HairSprite.texture = composite_sprites.Hair_spritesheet[current_hair] Any idea what I'm doing wrong? I figure if it works with +1 it should work with -1?
@ryancraven6720
@ryancraven6720 3 жыл бұрын
and of course, now that I posted it I figured out a work around. Simply replaced -1 with +24. Since there are 25 sprites in the dictionary, this an easy way to manually get around the issue of descending into negative numbers. Thought about deleting but maybe someone else will run into the same issue.
@ugbucket
@ugbucket 3 жыл бұрын
What was the game you had right there in the Top Right?
@dzhambulatnurmagomedov9001
@dzhambulatnurmagomedov9001 3 жыл бұрын
how did you animate all the different parts of the character? Did you hand draw animations for each item added to the game like...the running animation for the pants and shirts on the arms and such?
@Arkeve
@Arkeve 3 жыл бұрын
Yeah, I had to draw each frame. I could reuse some frames for certain situations (e.g. idle animation is similar for most the frames). Also for equipment (such as a sword) I only had to draw it once and played with position & rotation within the game engine without having to draw it each frame.
@ellakz8963
@ellakz8963 Жыл бұрын
How would one make it possible to switch the gender of the character which then switches which clothing or hair its able to use (if this question makes sense)
@sinbadfr4850
@sinbadfr4850 Жыл бұрын
hey @Arkeve would you be willing to make a tutorial about a save system for this character customization?
@dahyunkim4710
@dahyunkim4710 3 жыл бұрын
I have a problem. When I change the hair, clothes, etc., the skin tone is also changing.
@ItachiUchiha-ki2fr
@ItachiUchiha-ki2fr 4 жыл бұрын
It looks cool, but do I have to make animations for each clothing? That means 3 different walking down animations for 3 different shirts???
@Arkeve
@Arkeve 4 жыл бұрын
Yeah it would require you to do that, there are ways you can reduce the amount of work you do by reusing frames in certain instances. For example you can separate the shirt torso and sleeves and reuse the shirt torso for all the frames and just draw in the sleeves. With pixel art, the more customization you want to do the more work you generally have to do especially if you have a lot of animations. I usually try to be cautious adding more animations and try to reuse already drawn frames if i can to reduce work down the line.
@ItachiUchiha-ki2fr
@ItachiUchiha-ki2fr 4 жыл бұрын
@@Arkeve Alright, thx. Your game looks interesting btw
@ami7mina
@ami7mina Жыл бұрын
I have a new problem.. Since I have many preloaded suff my game has lag. barely can't move my character.
@ami7mina
@ami7mina Жыл бұрын
This tutorial makes my game lag. Is there a work around if I use AnimationPlayer?
@mustardseedfaith6888
@mustardseedfaith6888 3 жыл бұрын
Great tutorial! The one thing I can't figure out however is how to make the buttons work, when I press on them nothing happens
@v.chandrashekar3830
@v.chandrashekar3830 3 жыл бұрын
use on_button_pressed signel
@hannibalyin8853
@hannibalyin8853 2 жыл бұрын
okay so if I have say 200 hair styles, I have to make 200 sprite node?
@saulnores3477
@saulnores3477 3 жыл бұрын
Hi. This is great. But what if I have animated sprites instead of only sprites? Does it work?
@tuguldurbayartsolmon1852
@tuguldurbayartsolmon1852 3 жыл бұрын
how do i change particle texture like this
@ami7mina
@ami7mina Жыл бұрын
My, my! it worked!! If anyone had trouble with the button, I suggest making or reconnecting a new signal to it deleting the same one, cause my item names were different. But this video really works!! LOVE IT! My question is, how did you stop the player movement? I made a different scene and attached the buttons to that scene cause the Player node of mine can't have buttons because it is the actual moving player on the levels.
@ivanmectin9106
@ivanmectin9106 2 жыл бұрын
good if you could do a viewo onl loading and saving the characters :)
@doogl3661
@doogl3661 3 жыл бұрын
Hi! So at around 5:48 I am getting this error "Invalid get index 'body_spritesheet' (on base: 'GDScript')." I tried to search forums but everyone said it was an error with hierarchy of the nodes. I doubled checked it and have re did this tutorial a couple of times, but It still tends to not work. Any suggestions?
@doogl3661
@doogl3661 3 жыл бұрын
OH GOSH IM DUMB I MADE A VAR INSTEAD OF A CONST
@spexyfer1024
@spexyfer1024 2 жыл бұрын
@@doogl3661 I get the same error and i used cost could you help?
@chaokai3606
@chaokai3606 2 жыл бұрын
I have the same error, though i am using Const anyone able to help me out with this?
@danobra
@danobra 3 жыл бұрын
I appreciate the tutorial, but I got super lost. No idea what that $ sign should mean. I'm trying to make a character that is divided in 3 parts and the arms move when he is attacking, then is supposed to return to where it would be if the character didn't attack. I though I could use this, but I just couldn't keep up =\ Anywhere I can learn more about it?
@HoldFamily
@HoldFamily 3 жыл бұрын
The $ means get_node("What/You/Put/Here"), which just traverses and returns the node at that position in the hierarchy. You can learn more at: docs.godotengine.org/en/stable/getting_started/scripting/gdscript/gdscript_basics.html. You should look into asking for help at: www.reddit.com/r/godot/ or discord.gg/4JBkykG as well for more specific questions.
@yapayzeka
@yapayzeka 4 жыл бұрын
thank you very much the result is awesome. I just... want to say something feels awkward inside my feelings. too many same code dyping. this code is WET.
@agriasoaks6721
@agriasoaks6721 4 жыл бұрын
Arkeve-sensei, Does the 3d one work the same way?
@Arkeve
@Arkeve 4 жыл бұрын
The concept should be the same, I figure you would have multiple meshes and stitch the meshes together. If you want to change something e.g. the face you would swap the face mesh with another one.
@agriasoaks6721
@agriasoaks6721 4 жыл бұрын
@@Arkeve Thank you, Arkeve-sensei I've looked for godot character customization for a while and I'm glad I got here. I look forward to attending your next lesson
@ajinrenfire
@ajinrenfire 4 жыл бұрын
how to customize character and play with the same character
@Arkeve
@Arkeve 4 жыл бұрын
You would just set the sprites within your player scene to the ones you selected during customization. But you would have to make sprites for the clothing and rest for animations such as walking, attacking, etc.
@RandomGuy-kd3xs
@RandomGuy-kd3xs 3 жыл бұрын
Buddy which software you use for character
@Arkeve
@Arkeve 3 жыл бұрын
I use aseprite for pixel editing
@tonmate7175
@tonmate7175 2 жыл бұрын
skin color?
@Anonymousanimator234
@Anonymousanimator234 4 жыл бұрын
How do you make your costumes save system
@Arkeve
@Arkeve 4 жыл бұрын
How you save it can be flexible, for instance you can save the spritesheet paths for each clothing into a JSON file and load your textures using the paths saved.
@KyleSzklenski
@KyleSzklenski 3 жыл бұрын
There's something weird about this video. You're preloading a script with your composite sprites, which shouldn't do anything. Scripts don't really function outside of nodes in Godot, unless you make them singletons, in which case you wouldn't preload them, you'd just reference them directly. I think there must be something else going on in this video, and the preloading of a script is not what you want to be showing people, as it's not good practice, unless for some reason you need to attach the script to a node dynamically (in which case I'd just load a whole scene instead of just the script).
@ParkerDeVenney
@ParkerDeVenney 2 жыл бұрын
If any of y'all know how to do this in unity, hmu
@firstlast896
@firstlast896 4 жыл бұрын
Insomnia cured
@radthadd
@radthadd 3 жыл бұрын
Your sprites look like rpg maker's
@bubblemage
@bubblemage 2 жыл бұрын
What I don't get is why do people keep making the gender thing in customization menus. Why not simplify it and make a single body and you can customize it as much as you want? Isn't that a simpler way to do it? Separating it by gender is so pointless
@acinome9880
@acinome9880 4 жыл бұрын
Put me straight to sleep
@brysonmercury
@brysonmercury Жыл бұрын
Awesome!
7 Tips to Optimize Your Godot Game
5:23
Venex Source
Рет қаралды 11 М.
What will he say ? 😱 #smarthome #cleaning #homecleaning #gadgets
01:00
Touching Act of Kindness Brings Hope to the Homeless #shorts
00:18
Fabiosa Best Lifehacks
Рет қаралды 17 МЛН
나랑 아빠가 아이스크림 먹을 때
00:15
진영민yeongmin
Рет қаралды 14 МЛН
2D CHARACTER CUSTOMIZATION in Unity Tutorial
14:49
BMo
Рет қаралды 127 М.
How Games Make VFX (Demonstrated in Godot 4)
5:46
PlayWithFurcifer
Рет қаралды 340 М.
How Character Customization Actually Works In Video Games
3:32
So umm... Minecarts can delete players from the game.
5:42
Phoenix SC
Рет қаралды 507 М.
I Paid Fiverr Game Developers to Make the Same Game
10:25
BadGameDev
Рет қаралды 683 М.
I Made the Same Game in 8 Engines
12:34
Emeral
Рет қаралды 4 МЛН
Moving my game from Godot to Unreal
4:56
Arkeve
Рет қаралды 3 М.
The Most Impressive Scratch Projects
11:00
DenshiVideo
Рет қаралды 4,9 МЛН
Pixel Art Tips from a Professional Artist - Tips & Tricks
8:01
Goodgis
Рет қаралды 1,1 МЛН
The HARDEST part of game development | Devlog
6:16
Challacade
Рет қаралды 68 М.
What will he say ? 😱 #smarthome #cleaning #homecleaning #gadgets
01:00