diff options
| author | Savely Skresanov <savask@yandex.ru> | 2012-09-15 14:31:55 (GMT) |
|---|---|---|
| committer | Savely Skresanov <savask@yandex.ru> | 2012-09-15 14:34:27 (GMT) |
| commit | ec0dfa27e888461ec85012fa23d5a26e30f0e813 (patch) | |
| tree | 127dd057a10a8810ea14057d8da2e050655f3e1c /src/virtualmachine/Syscalls.cpp | |
| parent | b626864293a5cb4717303245095c6d6f39c52f7d (diff) | |
| download | powder-ec0dfa27e888461ec85012fa23d5a26e30f0e813.zip powder-ec0dfa27e888461ec85012fa23d5a26e30f0e813.tar.gz | |
Hooked more functions to VM.
Diffstat (limited to 'src/virtualmachine/Syscalls.cpp')
| -rw-r--r-- | src/virtualmachine/Syscalls.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/virtualmachine/Syscalls.cpp b/src/virtualmachine/Syscalls.cpp index 692d4d0..876fe52 100644 --- a/src/virtualmachine/Syscalls.cpp +++ b/src/virtualmachine/Syscalls.cpp @@ -71,10 +71,16 @@ namespace vm TRAPDEF(pmapData) { - int xarg, yarg; - yarg = ARG(0).int4; - xarg = ARG(1).int4; + Push<int4_t>(sim->pmap[ARG(1).int4][ARG(0).int4]); + } - Push<int4_t>(sim->pmap[yarg][xarg]); + TRAPDEF(deletePart) + { + sim->delete_part(ARG(0).int4, ARG(1).int4, ARG(2).int4); + } + + TRAPDEF(killPart) + { + sim->kill_part(ARG(0).int4); } } |
