Mix it, fam
This commit is contained in:
parent
9b8f4bbe7f
commit
c12595d548
4 changed files with 9 additions and 41 deletions
|
@ -1,28 +0,0 @@
|
||||||
#pragma strict
|
|
||||||
|
|
||||||
public var vs : int = 20;
|
|
||||||
public var hs : int = 40;
|
|
||||||
public var matrix : int[,]; //0 significa zona habitable
|
|
||||||
//dif de 0 zona no habitable
|
|
||||||
public var basic_floor : GameObject;
|
|
||||||
public var nhabitable_floor : GameObject;
|
|
||||||
|
|
||||||
function Start () {
|
|
||||||
var basic_floor_instance : GameObject;
|
|
||||||
for(var i : int = 0; i < vs; i++){
|
|
||||||
for(var j : int = 0; j < hs; j++){
|
|
||||||
if(matrix[i,j]==0) basic_floor_instance = Instantiate(basic_floor, Vector3(i,-0.5,j), Quaternion.identity);
|
|
||||||
else basic_floor_instance = Instantiate(nhabitable_floor, Vector3(i,0.5,j), Quaternion.identity);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function Update () {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
function setMatrix(new_floor : int[,], x : int, z : int){
|
|
||||||
matrix = new_floor;
|
|
||||||
vs = x;
|
|
||||||
hs = z;
|
|
||||||
}
|
|
|
@ -1,12 +0,0 @@
|
||||||
fileFormatVersion: 2
|
|
||||||
guid: 2b1e029f45d9d8349b5a1df7a70eebdd
|
|
||||||
timeCreated: 1477742960
|
|
||||||
licenseType: Free
|
|
||||||
MonoImporter:
|
|
||||||
serializedVersion: 2
|
|
||||||
defaultReferences: []
|
|
||||||
executionOrder: 0
|
|
||||||
icon: {instanceID: 0}
|
|
||||||
userData:
|
|
||||||
assetBundleName:
|
|
||||||
assetBundleVariant:
|
|
|
@ -62,6 +62,14 @@ public class TurnManagerScript : MonoBehaviour {
|
||||||
act (c);
|
act (c);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void attack(int i, int j, params int[] altParams ) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void attackRange (int i, int j, int k, int l, params int[] altParams ) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
void changeTeam (int newTeam) {
|
void changeTeam (int newTeam) {
|
||||||
actualPlayer = newTeam;
|
actualPlayer = newTeam;
|
||||||
//actualNumChars = charList [actualPlayer].Count;
|
//actualNumChars = charList [actualPlayer].Count;
|
||||||
|
|
|
@ -97,7 +97,7 @@ public class UnitBehaviour : MonoBehaviour {
|
||||||
if (attackHit ())
|
if (attackHit ())
|
||||||
attack = attackDamage;
|
attack = attackDamage;
|
||||||
if (criticalHit ())
|
if (criticalHit ())
|
||||||
attack = Mathf.CeilToInt(attack * 1.5);
|
attack = Mathf.CeilToInt(attack * 1.5f);
|
||||||
return attack;
|
return attack;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue