X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;f=src%2Ffontgfx.c;h=2abb13ffe93dfa88a15c9b88a486a67c169c7177;hb=900779b8b2ce8c05c3df897d3ae3fa5d8cb414c6;hp=90cc0b9e8538bb02019af0e7c5a73d43b1769895;hpb=67103bcf34caaa89876b908820771584b3f4d05c;p=16.git diff --git a/src/fontgfx.c b/src/fontgfx.c old mode 100644 new mode 100755 index 90cc0b9e..2abb13ff --- a/src/fontgfx.c +++ b/src/fontgfx.c @@ -1,5 +1,5 @@ /* Project 16 Source Code~ - * Copyright (C) 2012-2015 sparky4 & pngwen & andrius4669 + * Copyright (C) 2012-2016 sparky4 & pngwen & andrius4669 & joncampbell123 * * This file is part of Project 16. * @@ -25,27 +25,81 @@ //#include "lib/16text.h" #include "lib/modex16.h" +global_game_variables_t gvar; + void main(int argc, char near *argv[]) { //JMOJI - byte e; - word chx, chy; + static byte e; + //word ri; + byte pee[2]; + static byte ibmlogo[]="IIIIIII BBBBBBBBB MMMMM MMMMM\n\ +IIIIIII BBBBBBBBBBB MMMMMM MMMMMM\n\ + III BBB BBB MMMMMM MMMMMM\n\ + III BBBBBBBBB MMMMMMM MMMMMMM\n\ + III BBBBBBBBB MMM MMMMMMM MMM\n\ + III BBB BBB MMM MMMMM MMM\n\ +IIIIIII BBBBBBBBBBB MMMM MMM MMMM\n\ +IIIIIII BBBBBBBBB MMMM M MMMM\n\ +"; + static byte rose[]=" :. ,..\n\ + .' :~.':_.,\n\ + .' ::.::'.'\n\ + : ::' .:\n\ + `.: .: .:/\n\ + `::--.:'.::'\n\ + |. _:===-'\n\ + / /\n\ + ,---.---. __,','\n\ + (~`. \ ) )','.,---..\n\ + `v`\ | ,' .-'.:,'_____ `.\n\ + )|/.-~.--~~--. ~~~-. \ \n\ + _/-'_.-~ ""---.._`.|\n\ + _.-~~_.-~ ""'\n\ + _..--~~_.(~~\n\ + __...---~~~_..--~~\n\ +,'___...---~~~\n\ +"; +// static byte *rosa; + static word chx, chy, colpee; textInit(); - modexEnter(); + VGAmodeX(1, 1, &gvar); + /* setup camera and screen~ */ + gvar.video.page[0] = modexDefaultPage(&gvar.video.page[0]); + //gvar.video.page[0].width += (16*2); + //gvar.video.page[0].height += (16*2); +//++++ modexShowPage(&gvar.video.page[0]); //modexprint(16, 16, 1, 15, "wwww"); //getch(); chx=0; chy=0; - for(e=''; e<=''; e++) + colpee=32; + for(e=0x00; e<=0xFE; e++) { - modexprint(chx, chy, 1, 15, &e); - chx+=8; - if(chx+8>=SCREEN_WIDTH) + if(chx+8>(gvar.video.page[0].width/2)) { chx=0; chy+=8; + sprintf(pee,"%u", colpee); + modexprint(&gvar.video.page[0], 200, 200, 1, 47, 0, &pee, 1); + //getch(); } + modexprint(&gvar.video.page[0], chx, chy, 1, 0, colpee, &e, 1); + chx+=9; + colpee++; + if(colpee>=32+24) colpee=32; } + //modexprint(100, 100, 1, 47, 0, "wwww"); + getch(); +// modexprint(0, 0, 1, 0, colpee, &rose); +//++++ modexprint(&gvar.video.page[0], 0, 0, 0, 0, colpee, &ibmlogo); +// modexprintbig(&gvar.video.page[0], 0, 0, 1, colpee, 0, "IBM"); +// modexprint(0, 0, 1, 0, colpee, ROSE); getch(); - modexLeave(); + VGAmodeX(0, 1, &gvar); +// rosa=malloc(sizeof(ROSE)); +// (*rosa)=(byte)ROSE; + printf("\n%s\n", rose); + //printf("\nh=%d\n", '8'); +// printf("\n%c\n", e); }