A Smoll game engine
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

53 lines
988 B

  1. namespace Smoll.Ex4.Commands {
  2. interface IScriptable {
  3. }
  4. class Number : IScriptable {
  5. public double value;
  6. public Number(double value) {
  7. this.value = value;
  8. }
  9. public override string ToString()
  10. {
  11. return value.ToString();
  12. }
  13. }
  14. class Complex : IScriptable {
  15. public Complex value;
  16. public override string ToString()
  17. {
  18. return value.ToString();
  19. }
  20. }
  21. class Atom : IScriptable {
  22. public string value;
  23. public Atom(string value) {
  24. this.value = value;
  25. }
  26. public override string ToString()
  27. {
  28. return "[[" + value.ToString() + "]]";
  29. }
  30. }
  31. class String : IScriptable {
  32. public string value;
  33. public String(string value) {
  34. this.value = value;
  35. }
  36. public override string ToString()
  37. {
  38. return value;
  39. }
  40. }
  41. }