diff options
Diffstat (limited to 'libphysics/_map.c')
| -rw-r--r-- | libphysics/_map.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libphysics/_map.c b/libphysics/_map.c index 06d3cad..3057bf4 100644 --- a/libphysics/_map.c +++ b/libphysics/_map.c @@ -15,6 +15,9 @@ phxsetmap(int w, int h, int *tiles) if(phxmapbuffer) free(phxmapbuffer); + phxmapwidth = w; + phxmapheight = h; + phxmapbuffer = malloc(w * h * sizeof(phxmapbuffer[0])); memcpy(phxmapbuffer, tiles, sizeof(phxmapbuffer[0]) * w * h); } |
