add ckg
plantilla base para movimiento básico
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class characterSlowDownVelocity : characterStateAffectedInfo
|
||||
{
|
||||
[Header ("Custom Settings")]
|
||||
[Space]
|
||||
|
||||
public bool animationSpeedCanBeChanged = true;
|
||||
|
||||
public playerController mainPlayerController;
|
||||
|
||||
public override void activateStateAffected (float stateDuration, float stateAmount)
|
||||
{
|
||||
if (animationSpeedCanBeChanged) {
|
||||
if (mainPlayerController.usedByAI) {
|
||||
mainPlayerController.setNewAnimSpeedMultiplierDuringXTime (stateDuration);
|
||||
mainPlayerController.setReducedVelocity (stateAmount);
|
||||
|
||||
if (stateAmount < 0.09f) {
|
||||
mainPlayerController.setCanMoveAIState (false);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 2cd5c6eb833901047a911e5facc20c8c
|
||||
timeCreated: 1622030965
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 40995
|
||||
packageName: Game Kit Controller - Shooter Melee Adventure Creator 3D + 2.5D
|
||||
packageVersion: 3.77g
|
||||
assetPath: Assets/Game Kit Controller/Scripts/Player/States/Examples/characterSlowDownVelocity.cs
|
||||
uploadId: 814740
|
||||
@@ -0,0 +1,20 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class freezeCharacterState : characterStateAffectedInfo
|
||||
{
|
||||
[Header ("Custom Settings")]
|
||||
[Space]
|
||||
|
||||
public playerController mainPlayerController;
|
||||
|
||||
public int pauseCharacterPriority = 2;
|
||||
|
||||
public override void activateStateAffected (bool state)
|
||||
{
|
||||
GKC_Utils.pauseOrResumeCharacter (state, mainPlayerController, pauseCharacterPriority);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1fc7b51b556a889459c719994ea261c5
|
||||
timeCreated: 1658270083
|
||||
licenseType: Store
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
AssetOrigin:
|
||||
serializedVersion: 1
|
||||
productId: 40995
|
||||
packageName: Game Kit Controller - Shooter Melee Adventure Creator 3D + 2.5D
|
||||
packageVersion: 3.77g
|
||||
assetPath: Assets/Game Kit Controller/Scripts/Player/States/Examples/freezeCharacterState.cs
|
||||
uploadId: 814740
|
||||
Reference in New Issue
Block a user