From fa6e376242d7e7de95ff8419b226286b650fe304 Mon Sep 17 00:00:00 2001 From: Enne Walker Date: Sun, 29 Nov 2009 13:29:27 -0500 Subject: Change mapgrd and mapbld funcs to be 0-indexed. All the other dgn and map functions in Crawl are 0-indexed, so this makes everything more consistent. I've changed all the uses in the master branch, but if you're using these functions in another branch (dpeg and due), then you'll need to adjust all your coordinates to match. --- crawl-ref/docs/develop/levels/advanced.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'crawl-ref/docs') diff --git a/crawl-ref/docs/develop/levels/advanced.txt b/crawl-ref/docs/develop/levels/advanced.txt index a477d446e5..4a061f0034 100644 --- a/crawl-ref/docs/develop/levels/advanced.txt +++ b/crawl-ref/docs/develop/levels/advanced.txt @@ -811,11 +811,11 @@ Additionally, the dgn module provides a global "mapgrd" variable that can access the current map glyphs. The top left symbol in the map can be assigned like this: - mapgrd[1][1] = 'x' + mapgrd[0][0] = 'x' The bottom right symbol can be assigned like this: - mapgrd[width()][height()] = "." + mapgrd[width()-1][height()-1] = "." Lua API - global game state -- cgit v1.2.3-54-g00ecf