What do i want to achieve? I’m trying to acheive a smooth and fun combat system like the one in League of Legends, where each character got their own animations, particles, and different abilities from long range to melee attacks. im trying to “replicate” this system in roblox studio, i have high level of experience in 3d modeling, and medium level in scripting.
What is the issue? the issue im facing currently is understanding how to go about making this, i know i would have to create my custom characters, animate their movement and ability attacks, and make custom particles for each character, but how do i go about doing this? what services do i use? how do i go about making my particles? do i use parts? attachments? do i use weldConstraints to weld them to the player? or do i use Motor6D? how do i time my animation with my particles? all these question are confusing me.
What solutions have you tried so far? i haven’t tried anything so far as i have no idea where to start, i understand the general idea of what im trying to acheive but not the details and Parts needed.
Please, if you got experience or a general understanding in this topic and you have the time, please leave a comment to help me out, i will really appreciate it.
connect your system to some function like tool activation, then when you detect player in front of tool you will check if the player is blocking and if you are in front of him or smth, if yes then block attack, else deal damage
this is barely scratching the surface of the answer i was hoping to get, i have so much more question that need answering above.
thanks a lot for your time though!
For melee combat, I would look into shapecasting to check for players that are within a certain distance in front of the player.
For long-range weapons, a mere raycast should do the trick. You could use tools for this, but you don’t have to. It’s up to you.
As for your questions about welds and Motor6Ds, here’s a brief explanation on the difference:
Weld: Simply allows for a part to stick to another
Motor6D: Same as Weld, however allows for use (selection, movement, rotation) in animations
A Motor6D would definitely be what you’d need to attach animated weapons onto your character.
For particles, simply use ParticleEmitters. If you need to time them (or anything else) with certain events in your animations, look into Animation Keyframes and the KeyframeReached event.
I recommend you do some extensive research on some of these and watch some tutorials.
this is what i was looking for, great!
now i got 1 question for you, i know for melee combat its pretty simple stuff, but for the Long Ranged wepones would you say its best to use hitboxes? so i would create a hitbox that includes particles, and it would shoot out towards the enemy and detect hits and damage the enemy?
i know it might be a dumb question but im genuinely new to character combat systems,
For long-range weapons I would fire a Ray in a certain direction (from the mouse or tool/weapon for example). This will shoot through any part that is in that direction and return the first result. You could just clone something like a bullet, or your hitbox as mentioned, and move it along that ray.
From there you could either simply use a Touched event on your projectile/hitbox or utilize the result you received through the ray by damaging the opponent accordingly if the result part’s parent has a humanoid. However that could result in a humanoid taking damage even if the projectile missed (since rays are near instant and are invisible).