CreachoPedia/Creacher.cs

32 lines
1.0 KiB
C#
Raw Normal View History

2020-09-07 06:58:48 +00:00
using System;
using Newtonsoft.Json;
2020-09-07 06:58:48 +00:00
namespace creachopedia {
class Creacher {
public string name {get; set;}
// public int kingdom;
// public string description;
[JsonProperty]
private int _footsies { get; set; }
[JsonIgnore]
public int footsies {get { return this._footsies; } set { Console.WriteLine("What do you think you're doing?! 0uo Leave those footsies alone!!!"); }}
public string type = "simple creacher";
2020-09-07 06:58:48 +00:00
public Creacher(string name, int footsyCount = 4) {
this.name = name;
this._footsies = footsyCount;
2020-09-07 06:58:48 +00:00
}
public void Introduce() {
Console.WriteLine($"Hello, my name is... {this.name}. I am a {this.type}, and I have {this.footsies} footsies.");
}
public void Step(){
if(this.footsies == 0){
Console.WriteLine("I cannot stip or step! I have 0 footsies! I am however quite powerful in my own way 0u0");
Console.WriteLine("Silly creacher...");
} else {
Console.WriteLine($"The {this.name} steps, and rather well I might add.");
}
2020-09-07 06:58:48 +00:00
}
}
}