Prototype Spaceflight Controls in Unity3D

  Рет қаралды 18,300

Bit Galaxis

Bit Galaxis

Күн бұрын

Пікірлер: 29
@naveenthikshana4223
@naveenthikshana4223 4 жыл бұрын
Thank you for your tutorial i learn lot of things from this i searched 2 days to find this movement physics thank you again
@kvproductions2581
@kvproductions2581 4 жыл бұрын
I'm an amateur 3d modeller and texturer and animator now i'm learning unity. I want to make a star wars fangame which i'm planning to start developing and this will come up super useful!
@ropi6642
@ropi6642 4 жыл бұрын
good luck with the project :D
@kvproductions2581
@kvproductions2581 4 жыл бұрын
@@ropi6642 thanks! just yesterday i created a discord server for it and i'm modelling the ship i will use to try and get the basic mechanics down. it will be hard since im just starting with unity, but i bet it will be fun! also any devs willing to help are welcome :D
@carljakobson9314
@carljakobson9314 4 жыл бұрын
@@kvproductions2581 Whats the discord? :) I know this is pretty late, but i wanted to learn further into the space/airplane movement to make a x-wing flight sim! I would be happy to help and or see the product if you're done!!
@kvproductions2581
@kvproductions2581 4 жыл бұрын
@@carljakobson9314 I'm actually not the lead Dev anymore! a friend took that role and he's developing it in unreal! I'm helping him out with advice and research and 3d models and that stuff. The base game is not gonna be SW-Themed (as an excuse for it to not be taken down) but it's gonna be free, open source and easily moddable so we can quickly jump into modding it as soon as we have a good base and make a SW conversion mod! Here's the discord: discord.gg/m95VQ8X
@kvproductions2581
@kvproductions2581 3 жыл бұрын
@Samuel Jackson If you'd like me to join the team, I've got a ton of Star Wars ship models which I've made and I can share! Also i switched to UE4 and i'm a bit knowledgeable with it now
@NickyDekker89
@NickyDekker89 3 жыл бұрын
Great tutorial thanks! I'm trying to work out how I can point my ship into the direction my mouse cursor is pointing and control the thrust level through keyboard.
@ThePlasticPlanet
@ThePlasticPlanet 4 жыл бұрын
What would the code look like if I wanted to use yaw instead of roll?
@bitgalaxis1147
@bitgalaxis1147 4 жыл бұрын
First assign the horizontal input to yaw instead of roll: yaw = Input.GetAxis("Horizontal"); Then do either of the following (depending on which system you use: transform.Rotate(Vector3.up * yaw * 100f * Time.deltaTime, Space.Self); ============OR======================== rb.AddRelativeTorque(Vector3.up * torque * yaw);
@walney2008
@walney2008 4 жыл бұрын
hello, how to do those controls, for ships, as in the game Ship Simulator Extremes, as you push it forward, if you pull the lever it moves backwards, and if you turn the wheel, it turns the ship, at constant and slow speed, as it can be done, because have faster and slower ships, thanks
@walney2008
@walney2008 4 жыл бұрын
hello, I would like to learn how to do the movement of ships, as in the world of warships game, could you explain and thank you
@bitgalaxis1147
@bitgalaxis1147 4 жыл бұрын
That would be a lot more complex I have a link for AI that might help. What it looks like that game does is rotate the ship towards a selected target? Let me know if that's wrong. But, here's a link on how you can at least rotate towards a target >> kzbin.info/www/bejne/mHTdaJStecefa5o . The second half would be the selection of the target, but I don't have a video for that yet.
@phoenixorder539
@phoenixorder539 5 жыл бұрын
Alright so I guess I am struggling to wrap my head around this, So I have rewatched the video multiple times and understand what your trying to achieve and then you explain how you achieve it so after going through he each script I have realized I like the last one the best for the movement of the space ship, After copying the code and applying everything as you have my ship moves significantly slower than yours, almost unplayable so I decrease the mass almost to 100 and now it moves at a good speed, my question is why did I have to lower my mass so much to acquire the same speed as your ship? Edit: Also my turning is incredibly fast when I lower mass so i can't find an even balance as you have in your video, I am trying to see where I went wrong but I have yet to find anything, the only one I can get to work the same as the video is the first method you've shown Edit 2: have the 6th time watching I think I understand whats going on due to 12:50 - 13:25 you explain the troubles of spaceflight so I believe that is whats happening, enjoying the series keep it up !
@bitgalaxis1147
@bitgalaxis1147 5 жыл бұрын
Sorry for the troubles, but good to hear you figured it out! The settings I'd check are drag, angular drag, mass, torque values, and thrust values. Even with the settings I have in my project, there are issues. Increasing some of the drag values is really just a placeholder. In later videos, I intend to set up some scriptable-object-based dampeners where we can do live tweaks of the flight controls and change the drag values to make them more realistic. Edit: oh, and one more thing. In order for it to work like mine, you have to have a box collider that's about the same size as the one I've set for the model. So the final ship will be a bit different once we go through setting up the colliders. Center: x:0, y:0, z:0.0351696 Size: x:2.865187, y:0.8082633, z:4.366701
@goozebump
@goozebump 4 жыл бұрын
Use fixupdate for physics
@anotherrandominternetperso4994
@anotherrandominternetperso4994 4 жыл бұрын
Don´t you have to add *Time.deltaTime, when you are in fixedUpdate?
@bitgalaxis1147
@bitgalaxis1147 4 жыл бұрын
Probably... :X There are times it isn't necessary, but I may have missed something.
@anotherrandominternetperso4994
@anotherrandominternetperso4994 4 жыл бұрын
@@bitgalaxis1147 Ah, ok. Thank you!
@καλαμ
@καλαμ 4 жыл бұрын
@@anotherrandominternetperso4994 you need Time.fixedDeltaTime inside of FixedUpdate.
@anotherrandominternetperso4994
@anotherrandominternetperso4994 4 жыл бұрын
@@καλαμ Oh really? Well, that explains a lot....
@EthanEDITS1
@EthanEDITS1 4 жыл бұрын
Im having an issue where when I press space to go forward my spaceship goes left instead?Im using the first script by the way
@EthanEDITS1
@EthanEDITS1 4 жыл бұрын
nevermind the issue was my error.
@bitgalaxis1147
@bitgalaxis1147 4 жыл бұрын
@@EthanEDITS1 Glad you got it figured out! I forget to mention in my setups that my ship model is a child under a parent, which is actually rotated 180 degrees around the Y axis.
@Diertstarr
@Diertstarr 3 жыл бұрын
What did you use for the camera controller here?
@bitgalaxis1147
@bitgalaxis1147 3 жыл бұрын
On this I had a pretty basic script. If I recall correctly, the core functionality was based on code from Sebastian Lague.
@learningsomething8904
@learningsomething8904 4 жыл бұрын
Yes I'm a 100 th subscriber!
@ApocalypsFroid
@ApocalypsFroid 4 жыл бұрын
please share your project donwload :D
@bitgalaxis1147
@bitgalaxis1147 4 жыл бұрын
If you download my assets pack (link below) you'll have all the same code and assets that were used in this video (although not this exact scene). github.com/bitgalaxis/Free-Game-Assets
Making A Space Flying Game in 72 Hours
13:56
gamesplusjames
Рет қаралды 68 М.
Calculating Planet Gravity in Unity3D
25:34
Bit Galaxis
Рет қаралды 16 М.
小丑女COCO的审判。#天使 #小丑 #超人不会飞
00:53
超人不会飞
Рет қаралды 14 МЛН
Quilt Challenge, No Skills, Just Luck#Funnyfamily #Partygames #Funny
00:32
Family Games Media
Рет қаралды 54 МЛН
Flying Controls in Unity - Tutorial
27:00
gamesplusjames
Рет қаралды 92 М.
Spaceflight Controls Revisited
10:21
Bit Galaxis
Рет қаралды 1,2 М.
Simple Physics Based Plane Controller in Unity
28:43
b3agz
Рет қаралды 44 М.
THIRD PERSON MOVEMENT in Unity
21:05
Brackeys
Рет қаралды 1,5 МЛН
Unity3D Wheel Colliders
24:29
Bit Galaxis
Рет қаралды 32 М.
Thrust Vector Control for Rockets
15:19
Peter B
Рет қаралды 22 М.
Recreating No Man Sky without Coding in Unity
9:18
MadFinn13
Рет қаралды 19 М.
Understand Unity Rotation in 5 minutes
5:23
CodeForge
Рет қаралды 20 М.
Hover Physics in Unity3D
19:27
Bit Galaxis
Рет қаралды 15 М.
小丑女COCO的审判。#天使 #小丑 #超人不会飞
00:53
超人不会飞
Рет қаралды 14 МЛН