public int Go() { int unrealProgres; while (tilesCoords.Count != 0) { hikePlacement = tilesCoords[0]; unrealProgres = ReadLoadTile.ReadTileById(Map.GetTileByCoords(hikePlacement)).Walk(this, progress); if (unrealProgres != -1) { progress = unrealProgres; ReadLoadHike.SaveHike(this); return(0); } progress = 0; tilesCoords.RemoveAt(0); Downtime(); } quest.Play(this); if (!endOfTheHike) { PlayerInteractions.ContinueHike(this).Go(); } return(1); }
public void play(Hike nowHike) { Character subject; subject = PlayerInteractions.ChooseCharacter(nowHike); consequence.Play(nowHike, subject); }
static void Main(string[] args) { int[] att = new int[9] { 10, 10, 10, 10, 10, 10, 10, 10, 10 }; int[][] tal = new int[9][] { new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 }, new int[] { 10, 10, 10, 10, 10 } }; //Coords start = new Coords(2, 2); //Coords finish = new Coords(0, 0); //Character Alex = new Character("Alex", 1, att, tal, 100, 100, 100, 100); //Character Berta = new Character("Berta", 1, att, tal, 100, 100, 100, 100); //ReadLoadCharacter.AddNewCharacter(Alex); //ReadLoadCharacter.AddNewCharacter(Berta); //Console.WriteLine("({0}/{1}) {2}", Alex.GetWeaponeAttribute(), Alex.GetWeaponeTalent(), Alex.GetWeaponeDamage()); //Console.ReadLine(); Functions.SetIds(); Map.GetMap(); Character Alex = ReadLoadCharacter.ReadCharacterBySideAndId(1, 0); Character Berta = ReadLoadCharacter.ReadCharacterBySideAndId(1, 1); Alex.ShowAll(); Berta.ShowAll(); /*Character Clark = new Character("Clark", 1, att, tal, 100, 100, 100, 100); * ReadLoadCharacter.AddNewCharacter(Clark);*/ Character Dummy = ReadLoadCharacter.ReadCharacterBySideAndId(2, 2); Town.AddFreeCharacter(Alex); Town.AddFreeCharacter(Berta); Hike hike; do { hike = PlayerInteractions.StartHike(); hike.Go(); Console.WriteLine("Press 9 to end the program"); }while (Console.ReadLine() != "9"); //Hike hike = ReadLoadHike.LoadHike(0); //hike.Go(); ReadLoadCharacter.SaveCharacter(Alex); }
public void play(Hike nowHike) { if (PlayerInteractions.ChoosePassiveUse(passiveUseName, nowHike) >= requiredLevel) { Console.WriteLine(gDescription); nextEventt.Play(nowHike); } else { Console.WriteLine(bDescription); } }
public void play(Hike nowHike) { Character subject; subject = PlayerInteractions.ChooseCharacter(nowHike); if (Functions.TestCharacter(attribute, talent, difficulty, subject)) { nextGoodEventt.Play(nowHike); } else { nextBadEventt.Play(nowHike); } }
public void Continue() { for (int nowTile = 0; nowTile < tilesCoords.Count; nowTile++) { ReadLoadTile.ReadTileById(Map.GetTileByCoords(tilesCoords[nowTile])).Walk(this, progress); hikePlacement = tilesCoords[nowTile]; Downtime(); } quest.Play(this); if (!endOfTheHike) { PlayerInteractions.ContinueHike(this).Go(); } }
public void play(Hike nowHike) { Character subject; subject = PlayerInteractions.ChooseCharacter(nowHike); if (Functions.Test(subject.GetAttributeValue(attribute), subject.GetTalentValue(attribute, skill), difficulty)) { Console.WriteLine(gDescription); } else { subject.DamageCharacter(damage); Console.WriteLine(bDescription); } }
public void Downtime() { int cho; do { Console.WriteLine("Choose your downtime action:"); Console.WriteLine("0. Use an item"); Console.WriteLine("9. Go on"); cho = PlayerInput.Input(0, 10); switch (cho) { case 0: { PlayerInteractions.ChooseItem(this, PlayerInteractions.ChooseCharacter(this)); break; } } } while (cho != 9); }
public void play(Hike nowHike) { Character subject; subject = PlayerInteractions.ChooseCharacter(nowHike); if (Functions.Test(subject.GetAttributeValue(attribute), subject.GetTalentValue(attribute, skill), difficulty)) { Console.WriteLine(gDescription); foreach (Character subj in nowHike.GetAllCharacters()) { gConsequence.Play(nowHike, subj); } } else { Console.WriteLine(bDescription); foreach (Character subj in nowHike.GetAllCharacters()) { bConsequence.Play(nowHike, subj); } } }
public void play(Hike nowHike) { Console.WriteLine("Battle has started"); PlayerInteractions.StartBattle(nowHike, ReadLoadFight.ReadPlayerActionList(), ReadLoadFight.ReadTactic(idd)); }