Early Access, v1.0.1

This commit is contained in:
Nicola Sovic
2022-02-24 10:45:40 +01:00
parent 9610402e53
commit 639b127238
936 changed files with 75851 additions and 0 deletions

View File

@@ -0,0 +1,84 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
public class BasicSlime
{
protected int health;
protected int maxHealth;
protected int maxSecondary;
protected int secondary;
protected int strength;
protected int dexterity;
protected int intelligence;
protected int level;
protected int experience;
public BasicSlime(Player player)
{
// { health, maxHealth, secondary, maxSecondary, strength, dexterity, intelligence, playerlevel};
int[] playerStats = player.getStats();
maxHealth = playerStats[1];
health = maxHealth;
maxSecondary = playerStats[3];
secondary = maxSecondary;
strength = playerStats[4];
dexterity = playerStats[5];
intelligence = playerStats[6];
experience = (int)(10 + playerStats[7] * 1.5f);
level = playerStats[7];
}
public int[] getStats()
{
int[] result = { health, maxHealth, secondary, maxSecondary, strength, dexterity, intelligence };
return result;
}
public bool takeDamage(int amount, System.Random rand)
{
if (rand.Next(1, 101) > dexterity + (intelligence / 2))
{
health = health - amount;
}
return health <= 0;
}
public int calculateHeavy(System.Random rand)
{
int result = 0;
if (secondary >= maxSecondary / 2)
{
int bonus = 0;
if (rand.Next(1, 101) <= dexterity)
{
bonus = strength * 2;
}
result = strength + bonus + 10;
secondary = secondary - (maxSecondary / 2);
}
return result;
}
public int calculateDamage(System.Random rand)
{
int result;
int bonus = 0;
if (rand.Next(1, 101) <= dexterity)
{
bonus = strength * 2;
}
result = strength + bonus + 5;
return result;
}
public int getExperience()
{
return experience;
}
}
}

View File

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

View File

@@ -0,0 +1,23 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class BossSlime : BasicSlime
{
public BossSlime(Player player) : base(player)
{
intelligence = intelligence + 5;
strength = strength + 10;
maxHealth = maxHealth + 40;
health = maxHealth;
maxSecondary = maxSecondary + 20;
dexterity = dexterity + 5;
secondary = maxSecondary;
experience = experience * 2;
}
}
}

View File

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

View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
public class MageSlime : BasicSlime
{
public MageSlime(Player player) : base(player)
{
intelligence = intelligence + 2;
strength = strength - 2;
maxHealth = maxHealth - 10;
health = maxHealth;
maxSecondary = maxSecondary + 10;
dexterity = dexterity - 2;
secondary = maxSecondary;
}
}
}

View File

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

View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class MetalSlime : BasicSlime
{
public MetalSlime(Player player) : base(player)
{
//intelligence = intelligence;
strength = strength + 2;
maxHealth = maxHealth + 10;
health = maxHealth;
//maxSecondary = maxSecondary;
//dexterity = dexterity;
//secondary = maxSecondary;
}
}
}

View File

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

View File

@@ -0,0 +1,23 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class MiniBossSlime : BasicSlime
{
public MiniBossSlime(Player player) : base(player)
{
intelligence = intelligence + 3;
strength = strength + 3;
maxHealth = maxHealth + 20;
health = maxHealth;
maxSecondary = maxSecondary + 20;
dexterity = dexterity + 3;
secondary = maxSecondary;
experience = (int)(experience + experience * 0.5f);
}
}
}

View File

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

View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class NormalSlime : BasicSlime
{
public NormalSlime(Player player) : base(player)
{
maxHealth = maxHealth + 10;
health = maxHealth;
maxSecondary = maxSecondary + 10;
secondary = maxSecondary;
strength = strength - 2;
dexterity = dexterity - 2;
intelligence = intelligence - 2;
}
}
}

View File

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

View File

@@ -0,0 +1,46 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class SlimeFactory
{
public NormalSlime generateNormalSlime(Player player)
{
return new NormalSlime(player);
}
public MageSlime generateMageSlime(Player player)
{
return new MageSlime(player);
}
public MetalSlime generateMetalSlime(Player player)
{
return new MetalSlime(player);
}
public MiniBossSlime generateMiniBossSlime(Player player)
{
return new MiniBossSlime(player);
}
public WarriorSlime generateWarriorSlime(Player player)
{
return new WarriorSlime(player);
}
public WaterSlime generateWaterSlime(Player player)
{
return new WaterSlime(player);
}
public BossSlime generateBossSlime(Player player)
{
return new BossSlime(player);
}
}
}

View File

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

View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class WarriorSlime : BasicSlime
{
public WarriorSlime(Player player) : base(player)
{
intelligence = intelligence - 2;
strength = strength + 2;
maxHealth = maxHealth + 10;
health = maxHealth;
//maxSecondary = maxSecondary;
//dexterity = dexterity;
//secondary = maxSecondary;
}
}
}

View File

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

View File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Assets.Scripts.Slimes
{
class WaterSlime : BasicSlime
{
public WaterSlime(Player player) : base(player)
{
//intelligence = intelligence;
//strength = strength;
maxHealth = maxHealth + 10;
health = maxHealth;
maxSecondary = maxSecondary + 10;
dexterity = dexterity + 2;
secondary = maxSecondary;
}
}
}

View File

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