CreachoPedia/Creacher.cs

32 lines
No EOL
1 KiB
C#

using System;
using Newtonsoft.Json;
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";
public Creacher(string name, int footsyCount = 4) {
this.name = name;
this._footsies = footsyCount;
}
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.");
}
}
}
}