修改水

This commit is contained in:
2026-01-01 22:00:33 +08:00
parent 040a222bd6
commit 9ceffccd39
1800 changed files with 103929 additions and 139495 deletions

View File

@@ -0,0 +1,19 @@
// Crest Water System
// Copyright © 2024 Wave Harmonic. All rights reserved.
using UnityEngine;
namespace WaveHarmonic.Crest.Watercraft
{
/// <summary>
/// Controls provide input whether from the player or otherwise. Extend to
/// implement a control. See derived classes for examples.
/// </summary>
public abstract class Control : MonoBehaviour
{
/// <summary>
/// Provides input for controllers. XYZ is steer, float and drive respectively.
/// </summary>
public abstract Vector3 Input { get; }
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 5fd02b3521bc4486ea93e5a060580a53
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,35 @@
// Crest Water System
// Copyright © 2024 Wave Harmonic. All rights reserved.
using UnityEngine;
namespace WaveHarmonic.Crest.Watercraft
{
/// <summary>
/// Constantly moves/turns.
/// </summary>
[AddComponentMenu(Constants.k_MenuPrefixPhysics + "Watercraft Control (Constant)")]
public sealed partial class FixedControl : Control
{
[SerializeField, HideInInspector]
#pragma warning disable 414
int _Version = 0;
#pragma warning restore 414
[@GenerateAPI]
[Tooltip("Constantly move."), SerializeField]
float _Move = 0;
[@GenerateAPI]
[Tooltip("Constantly turn."), SerializeField]
float _Turn = 0;
#pragma warning disable UNT0001
// Here to force the checkbox to show.
void Start() { }
#pragma warning restore UNT0001
/// <inheritdoc/>
public override Vector3 Input => isActiveAndEnabled ? new(_Turn, 0f, _Move) : Vector3.zero;
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3a0773b7cb9424ddb87749b40d94c1ce
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: