forked from Sacchan-VRC/SaccFlightAndVehicles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Instructions.txt
561 lines (512 loc) · 41.9 KB
/
Instructions.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
Sacchan's Flight and Vehicles Prefab
FOR VRChat SDK3 WITH UDONSHARP: USE VRC'S CREATOR COMPANION APP TO CREATE YOUR PROJECT
Changelog is at the bottom
Contact:
https://discord.gg/Z7bUDc8
https://twitter.com/Sacchan_VRC
Please support me if you like this project:
https://ko-fi.com/sacchanvrc
Migrating a 1.62 project to 1.63 info:
In windows file explorer, delete the SaccFlightAndVehicles folder and replace it with the new version
The race system has a large update, if you have a racing world you must replace some things. Look at the SaccFlightExample.unity example scene to see it set up.
The RacingTrigger now has a prefab in the Prefabs/Accessories folder. Please replace your vehicles RacingTrigger with it.
The 'ThisSeatOnly' reference in SaccVehihicleSeat will be removed in version 1.7. There is currently 'ThisSeatOnly' AND 'EnableInSeat' array. Move your InVehicleOnly references into the new array to be ready.
Migrating a 1.61 project to 1.62 info:
In windows file explorer, delete the SaccFlightAndVehicles folder and replace it with the new version
The 'InVehicleOnly' reference in SaccEntity will be removed in version 1.7. There is currently 'InVehicleOnly' AND 'EnableInVehicle' array. Move your InVehicleOnly references into the new array to be ready.
There is a new folder inside the Prefabs called called 'Accessories' it's all the non-vehicle stuff and each part of 'SaccFlightAccessories.prefab' now has its own prefab
Migrating a 1.6 project to 1.61 info:
See the github's wiki for most up to date migration info.
Floatscript: Divide existing vehicle's Water Sideways Drag and Water Forward Drag by 4
The SF-1 mesh has been updated, so if you are using it's afterburner mesh, you need to fix the mesh reference on your mesh filters.
Known Issues:
There was a bug introduced in to VRChat around October that causes an important event not to fire in certain situations. See this canny link for details:
https://feedback.vrchat.com/udon-networking-update/p/1258-onownershiptransferred-does-not-fire-at-onplayerleft-if-last-owner-is-passi
This should be fixed soon, so I'm publishing the prefab without the workaround in place. The way it manifests is that a vehicle will become completely unresponsive to the master if the vehicle's owner leaves the world. Another player entering the vehicle should fix it.
The SaccWheel is not completely framerate dependant. Playing with a higher FixedUpdate rate will cause your vehicle to accelerate a bit faster. FixedUpdate rate in VRC is matched to headset's refresh rate.
Racing with 90hz against someone with 144hz is not a fair race.
I don't think I can fix this.
The SaccFlightMenu.cs editor script now sets up some things automatically when entering play mode, or building the scene. Things like the WindController no longer need you to manually assign all vehicles to them, it's done automatically.
I have done this with everything that requires simple lists to be filled out, or if there's only one of something in a scene that should be always be used. Things should be a little less fiddly to set up now. I plan to add more editor script stuff in future.
If you wish to run the code that does that stuff while in the editor, the option SaccFlight->Debug_OnBuild_SetReferences runs the function.
If you haven't set up a reference camera in your VRCWorld when you try to build the scene, It will be done automatically, matching how it's set up in Test Pilots.
Explanation of some scripts:
SaccEntity:
Main object script, sends events, has rigidbody on it.
SaccAirVehicle/SaccSeaVehicle/SaccGroundVehicle:
Main vehicle control scripts
SAV_EffectsController/SAV_SoundController:
Visual effects and audio effects for SaccAirVehicle
SGV_EffectsController:
Both visual effects and audio effects for SaccGroundVehicle
SaccWheel:
Wheel physics AND effects+sounds for the wheel
WaterTrigger:
Tells the vehicle when it enters and leaves water
SyncScript:
The custom position sync script
KillTracker:
Not required, used to make the KillsBoard work. Can be used without the killboard if you want to use the events that it sends for something else.
DFUNC_*
Pilot function dial scripts
DFUNCP_*
Passenger function dial scripts
EXTP_*
Specific passenger functionality that isn't compatable with function dials (only the turret atm)
Function dials:
SaccEntity has 2 arrays, one for left dial functions, and right dial functions.
Any number of functions can be placed in each array. The code divides the dial up automatically for selection. (Not visually, just for control input, you must make the visuals yourself)
The order they are input into that array is the order they'll work on the dial, clockwise. (First function is in straight up, unless the 'Left/RightDialDivideStraightUp' is ticked, in which case it's to the right of straight up. The ST-Baron's function dial uses this, if you need an example, the StickDisplay mesh is rotated negatively by half of a function)
The visuals of the function dial must be set up manually. Look at the dials in the vehicle prefabs in order to understand how.
The MFD.fbx file containts 12 divider meshes for function dials for dials with those number of functions. Named StickDisplay2-12 (the old default, 8, is just named 'StickDisplay')
Function dial scripts contain a 'funcon' (function on) reference if they are toggles. It's the mesh that appears to highlight the function on the dial when it's enabled.
To set the 'funcon' rotations, you can type '360/7' for example, into its Z rotation(if you have 7 functions). Then multiply the result by the dial position -1, then multiply by -1.
More info here: https://github.com/Sacchan-VRC/SaccFlightAndVehicles/wiki/Adding-and-Moving-Function-Dials-Functions
================================================================================================================
Inside the /Prefabs folder are individual prefabs for each vehicle, you can place them and they should work right away.
Open the example scene 'SaccFlightExample.unity' to see an example of vehicles set up to work with the Killsboard and racing scripts.
Race set up:
There's an object called RacingTrigger inside the InVehicleOnly/PilotOnly object, It should be disabled by default, it's enabled when a race is selected by the SaccRaceToggleButton script.
The SaccRaceToggleButton has a list of SaccRaceCourseAndScoreBoard objects and toggles through them when interacted with, enables the racingtrigger objects if a race is selected, and tells all racingtriggers to switch to the selected race.
The RaceToggleButton contains a hidden reference to every race, it's set up automatically on build.
Each race has its own script called SaccRaceCourseAndScoreBoard. This contains references for its race's checkpoints, and has text objects for displaying the times.
The RacingTrigger detects checkpoints, tracks your time, and sends your time to the SaccRaceCourseAndScoreBoard's SaccRaceTimeReporter script for the selected race when you finish.
Race checkpoints have an animation that enables guidance objects when the checkpoint is next or after next.
New in 1.63: Races have a full scoreboard showing everyones times. Times are reported by taking ownership of the SaccRaceTimeReporter object when you finish a race.
A delayed check is run by the player reporting their time to make sure that their time was actually recieved (if for example two people tried to take ownership/report their times at the same time). Missed times are re-submitted.
The RaceToggleButton now has a checkbox for [x]Automatic Race Selection
With this enabled you no longer need to select races, they will automatically enable when you go near either the beginning, or end of a race. Loop race's direction is decided by the direction you go through the start line.
Killsboard set up:
Place the killboard anywhere in the world, each vehicle that uses it must have its own SAV_KillTracker, referenced in it's SaccEntity's Extension Udon Behaviours list.
Some of the animations use the 'Motion Time' feature (formerly 'Normalized Time'), which makes the animation be controlled by a float parameter (which is controlled by effectscontroller).
float value 0(or less) = play the first frame of the animation
float value 1(or more) = play the last frame of the animation
and everything in between accordingly.
The MachVapor for example uses the mach10 variable. This variable = 1 at mach10, and 0 when not moving. The animation is 1000 frames long, and the MachVapor is enabled on frame 97 and disabled on frame 102, which corresponds to transitioning mach1.
This variable can be used to do other things like F-14 wings moving back at a certain speed.
The angle of attack variable is 0 at 0 AoA, and 1 at 180.
In Unity play mode testing using ClientSim, The SaccFlight script will cause your player to have 0 gravity (ClientSim bug). Just look straight down and hold F to fly down.
Making your own vehicles:
Aircraft:
When making a new vehicle, place the prefab that is closest in type to your desired vehicle and Unpack Prefab. Now your objective is to replace the mesh object (PlaneBody on the SF-1) completely.
I recommend just disabling it at first(delete it once you're done using it as a reference), and placing your mesh next to it on the hierarchy. The first thing you should do is set the VehicleMesh to your new mesh in the SaccAirVehicle script.
Next add colliders to your mesh(or armature), any collider types are fine. If your vehicle has wheels, i recommend copying the wheel colliders from the SF-1, and adjusting the size to fit your wheels.
Now go through the entire hierarchy and move all the empties, effects, and sounds to the proper position for your new vehicle.
Finally, duplicate the Animator for the vehicle prefab you used, rename it, place it in a new folder, apply it to your vehicle, and go through each layer and replace any animations that need replacing.
When you're done look at the EffectsController and SoundController, and make sure no array references are empty (the ones that you can change the length of), they're likely to crash if any are.
Tips for modifying basic flight characteristics of aircraft:
If it's having trouble taking off, try adjusting the center of mass and pitch moment positions, as well as the ground effect settings.
The Strength and Friction values for pitch, yaw, and roll are important, and both play off each other. You may need to set them to very high values, especially if you make a large plane.
Rot Multi Max Speed will need to be adjusted for planes with different speeds. It's the speed at which (in meters per second) the plane reaches maximum responsiveness.
Vel Straighten Str Pitch/Yaw are Very important to the handling of the plane. They push the nose toward the velocity direction. (they also interact with pitch and yaw strength)
Lift and Max Lift are also very important, and a bit tricky to tweak. If max lift is too high you can end up with a plane that can fly in circles extremely quickly. Reducing Max Lift will make the plane bleed much more speed in turns which is more realistic. Try around 3.
The Vel Lift/Max values are used to prevent the plane's nose from dropping constantly (counter gravity). Find a Vel Lift Max value that keeps the nose steady, Max is 10 by default but technically should be 9.81 to counter gravity exactly
Vel Lift value is used to decide how quickly the plane reaches Vel Lift Max.
Don't change the angular drag or drag of the rigidbody, drag is handled by the script, and angular drag is set by the script as a workaround for a sync issue.
If you use the 'Auto Adjust Values To Mass' option, you can set the rigidbody mass to any value you wish with no effect on the performance of the vehicle.
Using this option you will notice a lot of the SaccAirVehicle's values change when entering play mode. If you wish to tweak values during play mode, set the rigidbody mass to 1 temporarily so that they don't change.
Tips for VTOL Only aircraft:
For helicopters, keep the VTOL Thrust Vec values at 1, and adjust Pitch Yaw and Roll Strength
Pitch Down Lift Multi has a pretty big effect on how fast the vehicle can move forwards
The constant friction values are intended for helicopters (gyroscopic forces stop rotation)
You can make the blade tilt angle larger than implied in order to make the vehicle faster
Set Adverse yaw to 0 if you don't want the helicopter to spin when increasing the throttle
the Vel Straighten values are just as important for the handling of helicopters as planes
This file used to contain explanations of every variable in every script, that information is now contained in the tooltips of the variables. Hold the mouse still over a variable name in unity to see a description of what it does.
Guns work by having one particle system of visible bullets, and one particle system of invisible bullets that actually do damage which is only enabled for the firer. The Visible one is known as Gunparticle_other, and the pilot's damage one is known as GunParticle_pilot. Make sure if you change one, you change the other!
The Gun_pilot particle is what does damage to enemy planes. It is set to not collide with layer (OnBoardVehicleLayer(31)). The plane is set to OnBoardVehicleLayer you enter, so that you can't shoot your own plane, and reverted back to previous when you leave.
To make a gun do a different amount of damage, create a child empty game object under the 'GunParticle_pilot' particle system, and name it:
Damage:02 (2x damage). Damage:03 (4x damage), Damage:04 (8x damage), Damage:05 (16x damage). All the way up to Damage:14 works.
To do less damage use:
Damage:x2 (half damage), Damage:x3 (one third damage), Damage:x4 (quarter damage), Damage:x5 (fifth damage), Up to Damage:x9 works (one ninth damage)
The hud can be made to appear smaller by moving all children of the 'bigstuff' object +Z local. 'bigstuff' is a child of HudController.
The one exception is hud_elevation, it's position must be 0,0,0 in order for it to move correctly, the only resizing you can do to it and have its functionality remain correct is on the X axis.
Visual animations are done by either EffectsController directly, HudController if they're local/only when you're in the plane, or through the animator (via values sent to it by EffectsController or modular functions).
Doing animations using the animator is most performant, so I've used it where possible. Some HUD stuff included.
When making a custom plane, you must customize a number of the animations, I recommend duplicating the SF-1's animation controller and animations, and modifying the animations that need changing.
Likely to need replacing animations:
AAMs
AGMs
Bombs
Brake
CanopyOpen
Explode
FlapsOn
Mach
GearUp
TailHook
TailHookHooked
ThrottleSlider
EngineOutput
EngineOutputAB
Pitch
Yaw
Roll
Remember for animations that are controlled by floats that use motion time, set the animation curves to linear.
Joystick animation is done in the Pitch Yaw and Roll animations. Each one rotates a seperate empty of which the joystick is the last child of.
Hierarchy:
PlaneBody--------
Everything in here is visual, except that it also contains colliders, and wheel colliders. Objects can be placed as children of this if they need to move with parts of it (SS-1)
SaccAirVehicle--------
Children of this are transforms used by the SaccAirVehicle
EffectsController--------
The children of this are mostly particle systems, visual effects used by EffectsController and the animator.
SoundController--------
The children are all the sounds the plane uses. The AttachedSounds object contains all sounds that are disabled instantly when the plane explodes. The 'beeps' empty contains all the cockpit beep sounds, just move the 'beeps' object instead of all children individually.
InVehicleOnly--------
The children of this are all things that are disabled when you're not inside the vehicle. Many different objects are in here including the HUD and menus.
HUDController's 'bigstuff' child object is scaled to 720 to make the hud appear to be on the sky like a real HUD(roughly 1km away). You may want to scale it down to 1 temporarily if you plan on editing HUD elements.
PilotSeat--------
PassengerSeat--------
Custom station with seat adjustment code for entering the plane
AAMs--------
AGMs--------
Bombs--------
These 3 objects just contain meshes to visually represent how many missiles etc you have left. Controlled by the animator.
Cars:
Place the car prefab that matches closest with the car you want to create. You need to replace the mesh, animations, update the references and move everything into position.
Break the prefab completely, and place your new vehicle's mesh above the current mesh object. Set the position and rotation of the new mesh to 0,0,0, set Y rotation to match the original vehicle if necessary.
Disable the original vehicle mesh for now, we will copy some stuff from it soon.
Add collder to your new mesh, and modify it to fit. Any number of colliders is fine, but you cannot use mesh colliders that are not set to Convex.
Set mesh's main object to the Walkthrough layer (17)
The next step is to set up the wheels, which require a specific rig setup to work.
The hierarchy is as follows: The main wheel transform must be at the bottom of the tire, where it touches the ground, It should have a child that contains the mesh of the wheel.
The main wheel's transform orientation should be as follows: With 'Pivot' and 'Local' transform options selected, and the move tool selected, The blue arrow should point towards the front of the car, red to the right, and green up.
With this set up, the wheel's position you see in the editor will be the fully compressed suspension position. The ST-Baron is set up a bit weird because it was the first vehicle I created.
Copy the wheel script from the original car, and paste it on to each of your wheel's main transforms, (front and back wheel settings are usually a bit different, so you can copy the back to the back, and the front to the front)
Set each wheel's Wheel Point transform input to it's own gameobject, and Wheel Visual to the child object that contains the wheel mesh.
Move the gameobjects named SkidAudio_Tarmac, SkidAudio_Grass, SkidParticle_Tarmac, SkidParticle_Grass from the original mesh's wheels into each of your wheels, and make sure the references for them are set up in the 'Surface Type_Skid Sounds', and the 'Surface Type_Skid Particles' arrays.
You can now delete the original mesh object.
In the SaccGroundVehicle Object, update the references for:
Vehicle Mesh -> The mesh object you replaced the original with
Main Object Renderer -> Place the largest Mesh renderer/SkinnedMeshRenderer on your new mesh in this slot
Drive Wheels -> Put all wheels that are used to accelerate the car in here, usually the back wheels.
Steer Wheels -> Put all the wheels used for steering in here
Other Wheels -> Put in any other wheels
The functions for brake and handbrake also need to reference the wheels that they used. Go to DialFunctions/L/DFUNC_Brake and DFUNC_HandBrake and fix the missing references in the 'Brake Wheels_Front' and 'Brake Wheels_Back' arrays.
In each Wheel script, set the wheel radius to match your car's wheels. You can experiment with suspension values too. I recommend doing so in play mode. Make sure you're sitting in the driver seat so that the physics doesn't fall asleep.
Move the CoM object to where the center of mass for your new vehicle should be.
If you test your vehicle now it should be able to drive forward, but the suspension may be strange, and it won't be able to steer.
Steering is done through an animation. Duplicate the original vehicle's Animations folder and move it into your own folder.
Rename the animation controller in that folder to the name of your vehicle, and apply it to your vehicle's animator (it's on the vehicle's main object, same object as the rigidbody).
Go through each layer of the animator and replace each of the animation node's animations with the duplicates
Go through each of the animations and set them up with your new mesh. Refer to the original prefabs to see how they should be. The 'SteeringWheel' animation contains the movement of the steeringwheel and wheels.
Go through the whole hierarchy of the vehicle, and move everything to match the position of the new mesh. The eye position of seats is the 'TargetHeight' child object.
Info about surface types for SaccWheel scripts:
There's and array called 'Surface Type_Grips' with 10 entries. The object that the wheel is touching's name is checked,
and if it ends with a number, that number becomes the new surface type.
The grip of the wheel is multiplied by the corresponding element in this array, and the corresponding elements from the skid particles and sounds array are used for skids.
By default: 0 = Tarmac, 1 = Dirt/Grass, 2 = Ice. 4-9 are for you to define, but by default have same grip as tarmac. Any object without a number will be treated as tarmac.
There's a menu item at 'SaccFlight->Make All Static Colliders Tarmac...' that will rename all static colliders so that they are tarmac, you will then have to rename all dirt/other manually.
How to animate engine pitch:
In the 'Revs' animation, you will notice that the engine sound's audiosource's X Scale is animated. This is a workaround for setting engine pitch whilst also using doppler.
The code takes the X scale of the audiosource, applies doppler to it, then sets the pitch of the sound to it. Never animate the pitch directly.
If you wish to blend different engine sounds, it's possible to do it in this animation.
It's using motion time, so frame 0 = 0 revs, last frame = whatever revs SaccGroundVehicle's 'Rev Limiter' variable is set to.
Custom Layers:
Vehicle colliders must be set to Walkthrough layer in order to be targeted by AAMs. (Raycast looks for this layer)
Various functions require custom layers to be set up in order to work(Air-to-air-missiles, Air-to-ground custom targets, resupply zones, Arresting cables, and catapults)
To rename the layers for SaccFlight, there is a menu option under SaccFlight->RenameLayers, clicking it will instantly change the layer names.
References to the layers will be retained by prefabs and will work, but they will appear blank until named in Unity. Layers are as follows
23:Hook Cable
24:Catapult
25:AAMTargets
26:AGMTargets
27:Resupply
28:Racing
The trigger objects that you may need to change the layer of are in the prefabs listed below. The plane's AAMTarget is a child of SaccAirVehicle(If it's not, it will not be treated like a vehicle(untargetable on ground etc).
The AAMTarget object on a plane MUST be a first child of the SaccAirVehicle object, or the code to play the radar lock warning tone will fail.
This package also contains a few prefabs that can be used with the vehicles. Explanations follow.
AAMDummyTarget
Target object that can be placed on anything that you want air-to-air missiles to be able to lock on to. MUST be enabled at game start or planes will not detect it during initial target enumeration in Start(). After Start(), it can be disabled to become untargetable.
AGMLockTarget
object that if detected when attempting to lock target close to it with the AGM targeting system, will cause the targeted spot to snap to this location.
The trigger must be on the correct layer, the one selected in the DFUNC_AGM.
Arresting Cable
A prefab containing a cable mesh and a trigger designed to be placed on short runways or aircraft carriers to enable short landings.
The trigger must be on the correct layer, the one selected in the DFUNC_Hook.
Catapult
A prefab containing a catapult mesh and a trigger to enable the plane to launch quickly with no runway
The trigger must be on the correct layer, the one selected in the DFUNC_Catapult.
Catapult launches are controlled by an animation. The point in the animation where the trigger is disabled is the point at which the plane is released.
ResupplyZone
A prefab containing a square outline mesh with a trigger beneath it, used to reload, repair and refuel planes. Remove the mesh and just use the trigger if you want.
The trigger must be on the correct layer, the one selected in the ResupplyTrigger.
Target
A basic example target object with configurable health that respawns, replace with your own mesh to create destroyable buildings, etc. May not sync perfectly.
Killsboard
The board that tells you who has the biggest kill streak and number of vehicles destroyed, requires setup, see above
RadioBase
Contains the scipt for the radio system and a radio zone (stand inside to enable radio), vehicles require a SAV_Radio extension behaviour set up in their SaccEntity to work with the radio.
SaccFlight
Avatar flight script container
SaccFlightAccessories
Depracated. A bunch of stuff together, contains the iconic cuboid
SaccFlightMenu
Menu for the vehicle options
SaccViewScreen
View screen where you can watch vehicles/camera points
VehicleEnterer
A small menu that allows you to enter anyones vehicle
WindControl
A pickup with sliders on it that allow you to control the strength and direction of the wind. Click while holding to apply wind.
Changelog:
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Medium update 1.63
Added Biplane, Grappling Hook
Loop races + Race scoreboard
Radio channels
Fix a wheel physics issue (vehicles more stable)
Fix network sleep issue with ground vehicles
SyncScript initialization fix
Fix haptics issue on SeaVehicle
Vehicle teleporter
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small update 1.62
Many bug fixes
Grappling hook code improvements
Blocking players and respawning their plane no longer possible
Thumbstick steering option for cars
Animator boolean for 'invehiclesounds'
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Medium update 1.61
SF-1 and SH-1 now use SkinnedMeshRenderer/bones
Big improvement to vehicle sync smoothness
New vehicles: SH-1, ST-Thunder, S-GRVR
New vehicle functions: Grapple, 3DThrust, Consent
Radio scripts added
Added remote vehicle enterer
Improved Limits functionality
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Large Update 1.6
Added ground vehicle code and 3 car prefabs
Added some editor scripts to make life a bit easier
New vehicle menu
Small improvements to syncscript smoothness
Can now turn full 180 degrees in desktop mode while in vehicles (Thanks iffn!)
New vehicle guide
Now possible to set gun damage
A lot of missile code updates: notching, mimicking FOX-1-2-3 now possible
Vehicles can now stay 'on' after exiting if 'Auto Engine Start' is disabled
Weapons now use object pools
-Hundreds of small fixes and updates
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.51
Stopped using reserved2 layer (planes falling through floor)
SaccFlight menu started (Rename layers option)
AGMs can lock moving targets
Added splash effect for missiles hitting water
'Throw' variable to give missiles initial launch speed
Syncscript improvement (less jerky when watching someone crash/enter catapult)
Syncscript now has a proper 'slow mode' that smooths properly
Hoverbike stops hovering when out of fuel
Added 'dead' bool to animators
Stopped 'pitchdown' related physics from effecting yaw
SS-1 (boat) now sinks with physics rather than animation
All vehicles move their pivots to CoM on start, to improve rotation sync
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Modularization Update 1.5
Split functionality of EngineController into many different scripts allowing for greater customization
Function dial functions are now each their own script, allowing world creators to code their own
Now using an event system to send events to modular scripts
Added SB-1 hoverbike, SS-1 boat, SC-1 Seaplane, SaccStinger
Now using custom position synchronization code which allows formation flying and better dogfights
Fixed afterburner fuel consumption
Improvements to functionality of many of the now-modular function dial scripts
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Large Update 1.4
Added VTOL functionality and variables
Replaced Afterburner dial function with VTOL Angle
Afterburner now activated by pushing the throttle to max
Added SH-1 helicopter example vehicle
Added SF-1VTOL example vehicle
Textures for SF-1
Adverse Yaw and Roll options
Gun recoil option
Option to totally disable canopy for open cockpit vehicles
Various small optimizations
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.393
Compatibility for VRChat Networking Update
Throttle Now Unaffected by Object Scale
Throttle Sensitivity Option
Inertia Tensor Rotation adjustment Option
Minimum Bomb Drop Delay Option
Some Optimization
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix Update 1.392
Fixed vehicle respawner not setting the 'respawn' animation
Fixed Frontwheel movement
Set AtG render texture to something compatible with quest
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix Update 1.391
Hud lead indicator is now accurate
Made the NotDead event local only
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Large Update 1.39
Added racing objects and scripts
Added simple scoreboard that shows who has the highest kill streak in an instance
Ground Effect added, for much smoother takeoffs, removed Takeoff-assist variables
Replaced hardcoded control surface movement & engine effects with normalized-time animations
Hud almost perfectly synchronized for passengers (airspeed value is not correct if wind is enabled)
Added Bullet drop and corresponding hud prediction
Fixed VelLift variable to function how it was originally intended, so that it works with slower planes
Fixed bug that made the turn rate weaker the higher the refresh rate (removed double-deltatime)
Missiles now have a proximity explode radius option
AAGun updated with missiles and targeting
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.38
Workaround to allow players to hear each other talking in cockpit again (VRChat patch broke it)
Various Functions of the plane are no longer synced using synced variables (Flaps, Gear, Canopy, AB, Hook, Smoking, Missle/Bomb Ammo)
For late joiners things will sync when toggled or the plane respawns.
This should allow for more planes as each plane has less network overhead.
AGM Cam smoothing
Added Russian translation for the guide (Thanks AleksWS)
Various events added to the animator
Fixed Plane using its ground brake in the air when unoccupied, and other physics while unoccupied
No longer required to set up VRChat inputs in Unity, they're only checked in-game now
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.37
Gun Lead Indicator smoother
Missiles reverted to 1.35 because they were much more consistent
Animator events for firing weapons
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.36
Many small tweaks and bugfixes
Added Gun Lead Indicator
Improved missile tracking
Cable snap sound
Missiles unable to lock on through walls
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix Update 1.35
Added missing ViewScreen material
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.34
Added commented out elevon and ruddervator code to EffectsController, uncomment it if you need it.
Added channel number display to ViewScreen
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix Update 1.33
Fixed AoA effects appearing on stationary planes when wind is enabled
Tweaked AAM code to prevent possibility of firing at next target without locking if you fire on the frame target changes
Fixed Throttle Slider animation
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Small Update 1.32
Added plane view screen
Small changes to EffectsController to support view screen
Small fixes to guide images
Bomb angle randomization option
Fair number of small tweaks
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix Update 1.31
Emergency fix to seat exit code to support new VRChat patch
Some tweaks
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Major Update 1.3
VR Motion Controls for Joystick and Throttle
Function Dials with 16 functions for VR control
Air-to-air missiles
Air-to-ground missiles
Bombs
Fuel system
Ammo/Fuel/resupply system and animations
Arresting hook for aircraft carrier landings
Arresting cable prefab
Catapult launch functionality for carrier takeoffs
Catapult prefab
Afterburner
Air/ground brake
Customizable smoke color
Flight limits safety mode
Cruise mode
Altitude hold autopilot
Animated canopy with sound changes
Customizable wind functionality
Takeoff assist options
Sound barrier friction options
Many new sounds
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix 1.21
Fixed plane not exploding in editor test
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Major Changes in 1.2
Huge code changes in this version, back up your projects.
New Lift model, not floaty any more
Customizable lift based on angle of attack, allowing stalls
肘nverts control inputs if plane is moving backwards
Seperate thrust vectoring axis' strength
Square input on control stick, so that controller users don't have disadvantage against keyboard users
'Power' option for control stick for more precise input
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Major Changes in 1.17
Added fully animated HUD
Added mannable AAGun
Improved respawning
Changed roll behaviour
Many small tweaks and fixes
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix update 1.16
Fixed Respawn button
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Hotfix update 1.15
Fixed sync on Gun firing animation and Flaps animation
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Major Changes in 1.14
Removed other vehicles and attempted to optimized code for SF-1
Added Flares
Smoke is now operated by the pilot
Now makes use of animations for things it makes sense to for, flaps, exploding, gunfire etc.
Smoke effect when damaged
Seat Adjuster
Can no longer destroy your own plane with the machine gun
Renamed AircraftController to SaccAirVehicle
Merged AirplaneGunController into EffectsController
Atmospheric thinning
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Bugfix update 1.13
2 Small bugfixes.
Soundcontroller Sonic boom max distance fix
EffectsController Sea level now always destroys plane
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Bugfix update 1.12
Fixed: Vapor and Wingtrails don't show for people who aren't the owner of the vehicle
Fixed: Bug where respawning vehicles would explode instantly in a loop
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
I Suggest backing up your project before updating.
Major Changes in 1.11
A lot of variable names have changed so you will have to re-input values on most scripts. This was done because I removed RespawnTrigger.
Exploding planes. SF-1 now has HP and takes damage from crashing and getting shot.
I have also shuffled around the hierarchy of the SF-1 to support exploding more easily.
Replaced the respawntrigger with station triggers, and
Replaced the different LeaveButtons with just one
Custom Pitching Moment Setting
Might run a bit faster
Sea Level option on HUDController, plane explodes if you fly below it.
Passenger can make display smoke by holding S or clicking the left thumbstick .
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Changes in 1.1
Huge changes, too much to list. Some features:
Added SF-1 plane
Added SoundController
Doppler effect
Sonic booms
Added EffectsController
Control surface movement
Condensation
Machspeed vapor
Added HudController
Speed
Gs
Altitude
Landing Gear and Flaps status
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Changes in 1.02
Default Airplane Pitch Down Str Ratio changed from .6 to .8
Removed redundant object references in AircraftController.cs
Improved how VehicleRespawnButton.cs works
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Changes in 1.01
Roll now decays much faster in airplanes
Added option to disable thrust vectoring
Implemented (unrealistic) increased lift at higher speeds, you can now fall down faster at low speed
the two above combined should allow for more boring plane physics
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------