Q3D V-2.4 [3D Physics + Skeletal Animation UPDATE]

  • Looking great! I feel like it could use a little more silhouette contrast against the dark background.

  • yah I can fix the silhouette. good tip.

    More progress.

    Animations are mostly done. I still need to do the die one. but I am saving that for later when dying is actually programmed in.

    I only did two animations for now when it comes to the character. Being run forward and sidestep. I reverse them when the character is going the other way.

    Dot product came in helpful again. Each peer keeps track of the last x and y cords of each player. If they match then the system knows they are standing still and plays the idle animation. But if they don't match then it will get the dot product of where they are to where they were. And it can then play the correct direction accordingly.

    I also did the first person view of the weapon firing. will make the image bounce as you move but that will happen later.

    youtube.com/watch

  • Just an update on my project.

    I finished the player model for my project (finally!). it's not the best out there but for a first attempt at a 3d human model I think it came out good enough.

    for now I have rendered the first animation (idle) now I need to animate moving in 4 directions and dying.

    https://youtu.be/lBn9pP10gWY

    How u did this magic, plz share a tutorial for same.

  • I would be happy to share. what part specifically are you interested in?

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • adding a horde based survival mode.

    I am adding it so that way you can play on your own. but it will still work online for co op play

  • I would be happy to share. what part specifically are you interested in?

    How to move the character

  • jatin1726

    Just move the character? I'm not sure how to answer that as it depends on what you need moved, how it is moved, and what it interacts with. is it with default behaviors or something custom? are physics involved? Et cetera. It's not really a one size fits all thing.

    as for me I use physics movement. at the start of a players movement I set their velocity to zero. and then move them using the following physics velocity addition.

    x =(cos(angle_of_movment+player.angle)) * move_speed

    y =(sin(angle_of_movment+player.angle)) * move_speed

    sine and cosine works like an orbit. with angle_of_movment+player.angle specifying the angle relative to the center.

    angle_of_movment is the direction the player needs to travail represented as an angle between 0 and 360 (forward, backward, ect) however this number by itself will give the wrong direction as it is relative to the world. not the direction you face. hence...

    player.angle is the direction the player is facing. by adding this to the angle the player needs to go it makes the angle_of_movment relative to the player

  • bot support is coming along much nicer than I thought it would. Bots and players don't do damage to each other yet. but that will come.

    bots are red and players are yellow atm. players will be able to choose a color later. but for the sake of telling the bots apart from the players I kept it this way for now.

    no idea why their animation is getting stuck on the same frame. will need to look into that

    youtube.com/watch

  • jatin1726

    Just move the character? I'm not sure how to answer that as it depends on what you need moved, how it is moved, and what it interacts with. is it with default behaviors or something custom? are physics involved? Et cetera. It's not really a one size fits all thing.

    as for me I use physics movement. at the start of a players movement I set their velocity to zero. and then move them using the following physics velocity addition.

    x =(cos(angle_of_movment+player.angle)) * move_speed

    y =(sin(angle_of_movment+player.angle)) * move_speed

    sine and cosine works like an orbit. with angle_of_movment+player.angle specifying the angle relative to the center.

    angle_of_movment is the direction the player needs to travail represented as an angle between 0 and 360 (forward, backward, ect) however this number by itself will give the wrong direction as it is relative to the world. not the direction you face. hence...

    player.angle is the direction the player is facing. by adding this to the angle the player needs to go it makes the angle_of_movment relative to the player

    Is it possible to create a video for importing characrter(sprite or obj) and add the movement?

    That will be very helpful.

  • I’m not going to make a video on it as I don’t really have time. But also the truth is thats really it. All I did was add a physics behavior to the player. Every tick during the players movement the physics velocity is set to zero. And then I apply a physics force to the object in the direction I want the player to go. Then the physics behavior takes care of the rest. There is really not much more to it than that.

    Here is a picture of the code. I would suggest you gleam from it what you can and apply it to your own needs. something to keep in mind is my world is actually 2d. and I render the 3d one on top of it. so all of my movement is done with the normal C2 commands. I then use "on created" and "on destroyed" events to set up the 3d world. then those 3d assets are positioned in the same place as their 2d counterpart.

    I would suggest you experiment with it a bit. If you get stuck I will be happy to help iron out any issues. but again this is something you have to do for your own project. My code is custom made for my own needs.

  • > jatin1726

    Is it possible to create a video for importing characrter(sprite or obj) and add the movement?

    That will be very helpful.

    You might want to check out the Q3D tutorials:

    https://www.construct.net/en/tutorials/search?q=q3d&l=1

    They both should provide an overview of how to get started with Q3D. Maybe you can find what you are looking for in one of them?

  • A Quick update on my progress in the 3D Gamemode, soon to be added to DriftKing2D on Steam.

    i.imgur.com/UIV0oSU.mp4

    If there are any questions regarding Q3D, please ask. :)

    I didn't find the time to write a proper tutorial yet, But a screenshot and comment i can do.

    I've also got Local Multiplayer (Splitscreen up and running right now!)

    May i suggest everyone to join my Discord channel: discord.gg/AKsQjr

    I made a channel specifically for Q3D in which i plan to Collect as much documentation as possible which should speed everyone's development up by a lot.

    So we can more easily collaborate, share some info with each other (Especially sample screenshots of ingame & code!)

    This plugin still has some serious potential, But there's pretty much no documentation available! Why waste hours in figuring out why somethign works the way it does when we can make a proper manual? -Also very useful for our own future uses!)

    Let's stop the endless trial&Errors once and for all shall we?

    discord.gg/AKsQjr

  • looking sharp. it's using the q3d physics yah?

  • looking sharp. it's using the q3d physics yah?

    Actually, No.

    I found it a bit too unreliable so I'm using the good old C2 Solid behavior.

    The cars' physics are actually just 2 2D images.

    I'm trying a fake 2D jump & falling behavior as well which is the hardest part, I'd like the cars to jump & Fall. But i won't really need the behavior.

  • If you use the Q3DOimoPhysics behavior you will have gravity force on the Z axis.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)