diff options
author | Julien Dessaux | 2021-10-06 22:06:05 +0200 |
---|---|---|
committer | Julien Dessaux | 2021-10-06 22:06:05 +0200 |
commit | ba8933937e0b24e5a648ec176c4f0b8515fb0e2d (patch) | |
tree | 33ecdbf0e99eeee21a90a66aba21550dee6c6c74 /src/field.nim | |
parent | Implemented steps over a funge space field (diff) | |
download | nimfunge98-ba8933937e0b24e5a648ec176c4f0b8515fb0e2d.tar.gz nimfunge98-ba8933937e0b24e5a648ec176c4f0b8515fb0e2d.tar.bz2 nimfunge98-ba8933937e0b24e5a648ec176c4f0b8515fb0e2d.zip |
Implemented missing functions for the interpreter
Diffstat (limited to '')
-rw-r--r-- | src/field.nim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/field.nim b/src/field.nim index a9d706e..0a741c9 100644 --- a/src/field.nim +++ b/src/field.nim @@ -213,3 +213,6 @@ func Step*(f: Field, v: tuple[x, y: int], d: tuple[x, y: int]): (int, int) = if not f.IsIn(x2, y2): return (x, y) x = x2; y = y2 + +func GetSize*(f: Field): (int, int, int, int) = + return (f.x, f.y, f.lx, f.ly) |