1
0
Fork 0

Maikäfer + Spider

This commit is contained in:
Unknown 2018-04-23 16:08:16 +02:00
parent c066725024
commit 18ec2c326f
7 changed files with 66 additions and 21 deletions

View file

@ -28,16 +28,15 @@ public class BrakeBarController : MonoBehaviour {
private void UpdatePointer()
{
if (Input.GetKey(KeyCode.S))
while (Input.GetKey(KeyCode.S))
{
firstTime = Time.time;
firstTime += 1;
}
if (Input.GetKeyUp(KeyCode.S))
{
secondTime = Time.time;
float difference = secondTime - firstTime;
gameObject.transform.Rotate(Vector3.forward, difference);
gameObject.transform.Rotate(Vector3.forward, firstTime);
}

View file

@ -0,0 +1,20 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Assets.Scripts.Entities.Attack;
namespace Assets.Scripts.Entities {
public class Maikäfer : MonoBehaviourEnemy {
public Maikäfer() : base(15)
{
}
private void Start()
{
SetAttack(new MeleeAttack(this.gameObject));
}
}
}

View file

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

View file

@ -0,0 +1,20 @@
using System;
using System.Collections.Generic;
using UnityEngine;
using Assets.Scripts.Entities.Attack;
namespace Assets.Scripts.Entities
{
class Spider : Enemy
{
public Spider() : base(45)
{
}
private void Start()
{
SetAttack(new SingleShot(this.gameObject));
}
}
}

View file

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

View file

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 9ec323b9157704d00a3409f8ea6e46b2
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View file

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: df6e7833427b5497b92308fb6f54e552
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant: