From: sparky4 Date: Sun, 7 Sep 2014 06:08:09 +0000 (-0500) Subject: modified: 16/Project 16.bfproject X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=0668fdd349d09a439aa89a854754692e316df440;p=16.git modified: 16/Project 16.bfproject modified: 16/modex16/scroll.c modified: 16/modex16/scroll.exe modified: README --- diff --git a/16/Project 16.bfproject b/16/Project 16.bfproject index 8f32f009..7b17875c 100644 --- a/16/Project 16.bfproject +++ b/16/Project 16.bfproject @@ -1,17 +1,17 @@ c2e.convert_special: 0 e2c.convert_num: 0 -openfiles: /dos/z/16/16/dos_gfx.cpp:5935:5677:0: -openfiles: /dos/z/16/16/dos_gfx.h:910:518:0: +openfiles: /dos/z/16/16/dos_gfx.cpp:7655:7604:0: +openfiles: /dos/z/16/16/dos_gfx.h:910:295:0: openfiles: /dos/z/16/16/dos_kb.c:217:0:0: openfiles: /dos/z/16/16/dos_kb.h:161:0:0: openfiles: /dos/z/16/16/lib/lib_com.cpp:2:0:0: -openfiles: /dos/z/16/16/lib/lib_com.h:160:0:0: +openfiles: /dos/z/16/16/lib/lib_com.h:633:1027:0: openfiles: /dos/z/16/16/scroll.txt:5256:4537:0: openfiles: /dos/z/16/16/project16.txt:8063:6091:0: openfiles: /dos/z/16/16/16.txt:0:0:0: openfiles: /dos/z/16/16/lib/x/MODEX.H:5511:2798:0: openfiles: /dos/z/16/16/TEST.C:430:6112:0: -openfiles: /dos/z/16/16/modex16/scroll.c:2383:1718:1: +openfiles: /dos/z/16/16/modex16/scroll.c:1610:1479:1: snr_recursion_level: 0 convertcolumn_horizontally: 0 adv_open_matchname: 0 @@ -23,7 +23,7 @@ view_left_panel: 0 default_mime_type: text/plain e2c.convert_xml: 1 c2e.convert_iso: 0 -opendir: file:///dos/z/16/16/modex16 +opendir: file:///dos/z/16/16/lib wrap_text_default: 0 bookmarks_filename_mode: 1 ssearch_text: mapScrollRight @@ -82,19 +82,19 @@ recent_files: file:///dos/z/16/16/lib/types.h recent_files: file:///dos/z/16/16/modex16/PCXTEST.C recent_files: file:///dos/z/16/16/lib/MODEX16.C recent_files: file:///dos/z/16/16/lib/MODEX16.H +recent_files: file:///dos/z/16/16/modex16/SCROLL.C +recent_files: file:///dos/z/16/16/modex16/scroll.c recent_files: file:///dos/z/16/16/dos_gfx.h +recent_files: file:///dos/z/16/16/dos_gfx.cpp +recent_files: file:///dos/z/16/16/lib/lib_com.h recent_files: file:///dos/z/16/16/dos_kb.c recent_files: file:///dos/z/16/16/dos_kb.h recent_files: file:///dos/z/16/16/lib/lib_com.cpp -recent_files: file:///dos/z/16/16/dos_gfx.cpp -recent_files: file:///dos/z/16/16/project16.txt -recent_files: file:///dos/z/16/16/lib/lib_com.h recent_files: file:///dos/z/16/16/scroll.txt -recent_files: file:///dos/z/16/16/TEST.C +recent_files: file:///dos/z/16/16/project16.txt recent_files: file:///dos/z/16/16/16.txt +recent_files: file:///dos/z/16/16/TEST.C recent_files: file:///dos/z/16/16/lib/x/MODEX.H -recent_files: file:///dos/z/16/16/modex16/SCROLL.C -recent_files: file:///dos/z/16/16/modex16/scroll.c snr_replacetype: 0 savedir: file:///dos/z/16/16/modex16 spell_check_default: 1 diff --git a/16/modex16/scroll.c b/16/modex16/scroll.c index bd086732..034ff43f 100644 --- a/16/modex16/scroll.c +++ b/16/modex16/scroll.c @@ -47,14 +47,15 @@ void mapDrawCol(map_view_t *mv, int tx, int ty, word x); void main() { int show1=1; int tx, ty; - int x, y; + int x, y; + int ch=0x0; page_t screen; map_t map; map_view_t mv; byte *ptr; /* create the map */ - map = allocMap(80,60); + map = allocMap(40,30); initMap(&map); mv.map = ↦ @@ -66,36 +67,46 @@ void main() { mv.page = &screen; mapGoTo(&mv, 0, 0); modexShowPage(mv.page); - - /* scroll all the way to the right */ - for(x=0; x<(map.width*16-SCREEN_WIDTH); x++) { - mapScrollRight(&mv, 1); + + while(1){ + // scroll all the way to the right + //for(x=0; x<(map.width*16-SCREEN_WIDTH); x++) { + if(ch==0x4d){ + mapScrollRight(&mv, 4); modexShowPage(mv.page); } - /* scroll all the way to the left */ - for(; x>0; x--) { - mapScrollLeft(&mv, 1); + // scroll all the way to the left + //for(; x>0; x--) { + if(ch==0x4b){ + mapScrollLeft(&mv, 4); modexShowPage(mv.page); } - /* scroll all the way down */ - for(y=0; y<(map.height*16-SCREEN_HEIGHT); y++) { - mapScrollDown(&mv, 1); + // scroll all the way down + //for(y=0; y<(map.height*16-SCREEN_HEIGHT); y++) { + if(ch==0x50){ + mapScrollDown(&mv, 4); modexShowPage(mv.page); } - /* scroll all the way up */ - for(; y>0; y--) { - mapScrollUp(&mv, 1); + // scroll all the way up + //for(; y>0; y--) { + if(ch==0x48){ + mapScrollUp(&mv, 4); modexShowPage(mv.page); } - /* spin for a time */ - for(x=0; x<500; x++) { + // spin for a time + /*for(x=0; x<500; x++) { modexWaitBorder(); - } - + }*/ + //while(1){ + ch=getch(); + //printf("0x%02x\n", ch); + if(ch==0x71)break; // 'q' + if(ch==0x1b)break; // 'ESC' +} modexLeave(); } diff --git a/16/modex16/scroll.exe b/16/modex16/scroll.exe index 26addeed..6990eccd 100755 Binary files a/16/modex16/scroll.exe and b/16/modex16/scroll.exe differ diff --git a/README b/README index ac3e0cfb..99c5c0ab 100644 --- a/README +++ b/README @@ -4,7 +4,11 @@ Open watcom to compile the code of project 16 16/modex16/ = pngwen's code TODO: -1. SCROLLING!!!!!!! +DONE almost 1. SCROLLING!!!!!!! 2. Fix pngwen's pcx rendering code it dose not render large relolution pcx files well at all! 3. document an understrand how the main engine code works! -4. make the $#@%# game! +4. movement and player movement when reaching edge of map +5. sprite rendering +6. text box rendering +7. text rendering +8.