From ff87574df279952dc2e4646384e9f9a88fd7392a Mon Sep 17 00:00:00 2001 From: helixhorned Date: Sat, 14 Nov 2015 23:40:58 +0000 Subject: [PATCH] Mapster32: in a.m32, draw color info ("set showpal 1") more informatively. - draw ticks above the palette "ruler" - draw all editor colors (colors in editorcolor[]) git-svn-id: https://svn.eduke32.com/eduke32@5428 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/package/sdk/samples/a.m32 | 37 ++++++++++++++++++++--- 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/polymer/eduke32/package/sdk/samples/a.m32 b/polymer/eduke32/package/sdk/samples/a.m32 index a2ba248a5..c695e3209 100644 --- a/polymer/eduke32/package/sdk/samples/a.m32 +++ b/polymer/eduke32/package/sdk/samples/a.m32 @@ -1409,8 +1409,8 @@ ends onevent EVENT_DRAW2DSCREEN - var tmp - var xx yy + var tmp tmp2 + var xx xx2 yy state userdrawlabel @@ -1427,6 +1427,21 @@ onevent EVENT_DRAW2DSCREEN set xx 100 for tmp range 256 { + set tmp2 tmp + mod tmp2 64 + ife tmp2 32 + { + drawline16 xx 95 xx 99 15 + qsprintf TQUOTE "%d" tmp + printext16 TQUOTE xx 80 23 0 0 + } + else ife tmp2 0 + { + drawline16 xx 90 xx 99 15 + qsprintf TQUOTE "%d" tmp + printext16 TQUOTE xx 80 15 0 0 + } + drawline16 xx 100 xx 200 -tmp add xx 1 drawline16 xx 100 xx 200 -tmp @@ -1440,13 +1455,25 @@ onevent EVENT_DRAW2DSCREEN } } + set xx 100, set xx2 260 set yy 208 - for tmp range 16 + for tmp range 256 { qsprintf TQUOTE "editor color %d" tmp - printext16 TQUOTE 100 yy tmp 0 0 - printext16 TQUOTE 260 yy 0 tmp 0 + printext16 TQUOTE xx yy tmp 0 0 + printext16 TQUOTE xx2 yy 0 tmp 0 + add yy 8 + + set tmp2 tmp + mod tmp2 64 + + ife tmp2 63 + { + set yy 208 + add xx 320 + add xx2 320 + } } } endevent