DOS Games Message Board
DOS Games Discussion
A message board to talk about DOS games, get help, and find old games.
Do NOT post warez or abandonware requests please
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
NEW! DOSGames.com has been massively upgraded to v2.0 with TONS of new features!
Check out the new design and dozens of new features including online play!


What game would you like to make according to my skill level
Goto page Previous  1, 2, 3
 
Post new topic   Reply to topic    DOS Games Discussion Forum Index -> Game Creation
Author Message
tienkhoanguyen
PSEUDOCODER


Offline
Joined: 05 Sep 2014
Posts: 2664
Location: Texas

PostPosted: Sun Dec 14, 2014 2:38 pm     Post subject: "God, Cheese-its & Rice, is number one!hehe" - my quote Reply with quote

"Cheese-its & Rice!hehe" - my quote haha

Well, I figure the people on Windows might like to see a little something...
.........

So here are pre-packed Windows version using DOSBox 0.74:

http://www.mediafire.com/download/ac58a3a5a76utah/LineDemo.exe

http://www.mediafire.com/download/7xcxob4b1p4yy5y/JsideRPG.exe

Both game super little DEMO uses keyboard and SONY PSone controller.

Remember The SONY PSone controller has a USB adapter.

Thank you Cheese-its & Rice.

For those who prefers DOSBox version, there is not much new here.
Back to top
pseudocoder
Experienced Member
Experienced Member


Offline
Joined: 23 Nov 2014
Posts: 76

PostPosted: Thu Dec 18, 2014 12:12 am     Post subject: Re: God, Cheese-its & Rice, is number one!hehe Reply with quote

tienkhoanguyen wrote:
This is my remake to @pseudocoder.

That's pretty good - I like the cross hair and line plotting; the frogger demo was well done too. Keep up the good work. Happy

I do have a question though; why so much inline assembler in C code? You might try writing a static lib for the common functions such as the game pad routines, maybe put, peek pixel, etc. That way, you wouldn't be redoing the same code with every new variation or demo.
Back to top
Quadko
Darklander
Darklander


Offline
Joined: 24 Jun 2011
Posts: 2032

PostPosted: Thu Dec 18, 2014 11:18 am     Post subject: Reply with quote

Wow, I'm way behind. I'll try to catch up this week, looking forward to seeing the latest!
Back to top
Quadko
Darklander
Darklander


Offline
Joined: 24 Jun 2011
Posts: 2032

PostPosted: Thu Dec 18, 2014 4:22 pm     Post subject: Reply with quote

I stumbled across the C64 game Diagon featured on Moby, and the youtube gameplay video seemed both fun and completely something in your skillset, tien. Thought I'd mention it to see if it sparks any interest for you. Spaceships, blocking areas, shoot the moving aliens, polished in a little screen-clearing game. Congratulatory
Back to top
tienkhoanguyen
PSEUDOCODER


Offline
Joined: 05 Sep 2014
Posts: 2664
Location: Texas

PostPosted: Sat Dec 20, 2014 4:30 pm     Post subject: Cheese-its & Rice! hehe Reply with quote

@pseudocoder:

I only problem is pointers so it is hard to explain but...
.....that is why too many inlines.

@Quadko:

Looks like fun to play but im still in moving
Back to top
pseudocoder
Experienced Member
Experienced Member


Offline
Joined: 23 Nov 2014
Posts: 76

PostPosted: Mon Dec 22, 2014 7:40 pm     Post subject: Re: Cheese-its & Rice! hehe Reply with quote

tienkhoanguyen wrote:
@pseudocoder:
I only problem is pointers so it is hard to explain but...
.....that is why too many inlines.


Yeah; games are a headache - I tip my hat to all those who develop the games. For grins, I took a partial stab at a text based pacman clone (no skill set at all in graphics or assembly).

Hopefully the code won't be cropped or maybe that would be for the best. Tbbbbbth! Anyway - this junk needs worker threads, but TC wants no part of that.

Code:

/*
    "pacman".c

    requires c style comments for TC 2.xx // is C++
    compiler: bcc 5.5 (free command tools version)

    text based pacman clone attempt; probable
    bugs, but it's a start.

    ghosts not yet implemented
*/

#include <stdio>
#include <string>
#include <stdlib>
#include <time>
#include <ctype>
#include <conio>

#define MAX_X 23
#define MAX_Y 21
#define OFF_X -1
#define OFF_Y -1

#define BLANK  0x20
#define POWER  0x02
#define SCORE  0xF9
#define PACM   0x02
#define GHST   0x01
#define DEAD   0xEC
#define WALL   0xDB
#define HOLE   0xCD

#ifdef BYTE
#undef BYTE
#define BYTE unsigned char
#else
#define BYTE unsigned char
#endif

enum pm_ghosts { G_BLINKY = 0, G_PINKY, G_INKY, G_CLYDE };

#define PMAN_PLACE(x, y, c)\
{\
    textcolor(14);\
    textbackground(0);\
    gotoxy((x), (y));\
    cprintf("%c", (c));\
}

#define PMAN_CLEAN(x, y, c)\
{\
    textcolor(7);\
    textbackground(0);\
    gotoxy((x), (y));\
    cprintf("%c", (c));\
}

#define PMAN_SCORE(s)\
{\
    textcolor(7);\
    textbackground(0);\
    gotoxy(1, 24);\
    cprintf("%s", (s));\
}

#define GHOST_PLACE(x, y, g)\
{\
    textcolor((g) == G_BLINKY ? RED :\
              (g) == G_PINKY ? LIGHTRED :\
              (g) == G_INKY ? LIGHTGREEN : BROWN );\
    textbackground(0);\
    gotoxy((x), (y));\
    cprintf("%c", GHST);\
}

#define GHOST_FLASH(x, y, g, p)\
{\
    if((p) < 40)\
    {\
        textcolor((p) % 2 == 0 ? 1 : 7);\
        textbackground((p) % 2 == 0 ? 7 : 1);\
        gotoxy((x), (y));\
        cprintf("%c", GHST);\
    }\
    else\
    {\
        textcolor((p) % 2 == 0 ? 4 : 7);\
        textbackground((p) % 2 == 0 ? 7 : 4);\
        gotoxy((x), (y));\
        cprintf("%c", GHST);\
    }\
}

/* vv broken ATM vv */
#define VPORT_FLASH()\
{\
    int i = 0;\
    while(i < 40)\
    {\
        textcolor(0);\
        textbackground(7);\
        textcolor(7);\
        textbackground(0);\
        clrscr();\
        ++i;\
    }\
}

void vport_initView(char vp[][MAX_X + 1]);

int main()
{
    int i, j, init_game = 1,
        x = 12, y = 16,
        ox = x, oy = y,
        c = BLANK,
        i_score = 0,
        i_lives = 3,
        g_timer = 0,
        g_flash = 0;

    int g1_x = 12,
        g1_y =  9,
        g2_x = 10,
        g2_y = 10,
        g3_x = 12,
        g3_y = 10,
        g4_x = 14,
        g4_y = 10;

    int count_s = 0,
        count_p = 0;

    char s_score[30] = { 0 };
    BYTE vport[MAX_Y][MAX_X + 1];

    #ifdef _NOCURSOR
        _setcursortype(0); /* TC 201 doesn't seem to have this function */
    #endif

    textmode(C40);
    clrscr();

    for(;;)
    {
        if(init_game == 1 || (count_s == 150 && count_p == 4))
        {
            /* initialize entities */

            x  = 12; y = 16;
            ox = x; oy = y;
            c  = BLANK;

            g1_x = 12; g1_y =  9;
            g2_x = 10; g2_y = 10;
            g3_x = 12; g3_y = 10;
            g4_x = 14; g4_y = 10;

            textcolor(7);
            textbackground(0);
            clrscr();

            vport_initView(vport);

            for(i = 0; i < 21; ++i)
            {
                gotoxy(1, i + 1);
                cprintf("%s", vport[i]);
            }

            init_game = 0;
            count_s = 0;
            count_p = 0;
        }

        sprintf(s_score, " Score: %6d     %c%c%c",
                i_score,
                i_lives == 3 ? PACM : ' ',
                i_lives == 3 ? PACM : ' ',
                i_lives == 3 ? PACM : ' ');
        PMAN_SCORE(s_score);

        PMAN_PLACE(x, y, PACM);

        if(g_flash == 0)
        {
            GHOST_PLACE(g1_x, g1_y, G_BLINKY);
            GHOST_PLACE(g2_x, g2_y, G_PINKY);
            GHOST_PLACE(g3_x, g3_y, G_INKY);
            GHOST_PLACE(g4_x, g4_y, G_CLYDE);
        }
        else
        {
            if(g_timer < 50)
            {
                /* needs a worker thread; timers are blocking */
                clock_t tmr;

                GHOST_FLASH(g1_x, g1_y, G_BLINKY, g_timer);
                GHOST_FLASH(g2_x, g2_y, G_PINKY,  g_timer);
                GHOST_FLASH(g3_x, g3_y, G_INKY,   g_timer);
                GHOST_FLASH(g4_x, g4_y, G_CLYDE,  g_timer);

                tmr = clock() + 0.25 * CLOCKS_PER_SEC;
                while(clock() < tmr){}

                ++g_timer;
            }
            else
            {
                g_timer = 0;
                g_flash = 0;
            }
        }

        if(kbhit()) /* comment out line */
        {  /* comment out line */

        i = getch();

        if(tolower(i) == 'q') break;
        if(i == 0)
        {
            j = getch();

            if(j == 75 && (vport[y + OFF_Y][x + OFF_X - 1] == SCORE ||
                           vport[y + OFF_Y][x + OFF_X - 1] == BLANK ||
                           vport[y + OFF_Y][x + OFF_X - 1] == POWER))
            {
               if((y + OFF_Y == 9) && (x + OFF_X - 1 <1>= 21))
                    x = 3;
                else
                    ++x; /* right */
             }
            if(j == 72 && (vport[y + OFF_Y - 1][x + OFF_X] == SCORE ||
                           vport[y + OFF_Y - 1][x + OFF_X] == BLANK ||
                           vport[y + OFF_Y - 1][x + OFF_X] == POWER))
            {
                --y; /* up */
            }
            if(j == 80 && (vport[y + OFF_Y + 1][x + OFF_X] == SCORE ||
                           vport[y + OFF_Y + 1][x + OFF_X] == BLANK ||
                           vport[y + OFF_Y + 1][x + OFF_X] == POWER))
            {
                ++y; /* down */
            }
        }

        }  /* comment out line */

        c = vport[oy + OFF_Y][ox + OFF_X];

        if(c == SCORE)
        {
            i_score += 10;
            ++count_s;
            c = BLANK;

            vport[oy + OFF_Y][ox + OFF_X] = c;
        }
        else if(c == POWER)
        {
            i_score += 50;
            ++count_p;
            c = BLANK;

            vport[oy + OFF_Y][ox + OFF_X] = c;

            g_flash = 1;
        }
        else if(c == GHST)
        {
            i_lives -= 1;
        }

        PMAN_CLEAN(ox, oy, c);

        ox = x;
        oy = y;
    }

    /* TC 201 doesn't seem to have _setcursortype;
       bcc 5.5 won't run in dosbox
       go figure
    */
    #ifdef _NOCURSOR
        _setcursortype(2);
    #endif

    /*******************************************************************/

    textbackground(0);
    textcolor(7);
    textmode(C80);

    clrscr();

    return 0;
}

void vport_initView(char vp[][MAX_X + 1])
{
    BYTE init_view[][MAX_X + 1] =
    {
        { BLANK, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, WALL, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, POWER, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, POWER, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, WALL, WALL, SCORE, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, WALL, WALL, SCORE, WALL, SCORE, WALL, WALL, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, WALL, SCORE, SCORE, SCORE, WALL, WALL, WALL, SCORE, SCORE, SCORE, WALL, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, BLANK, WALL, WALL, WALL, BLANK, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, WALL, BLANK, 0 },
        { BLANK, BLANK, BLANK, BLANK, WALL, SCORE, WALL, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, WALL, SCORE, WALL, BLANK, BLANK, BLANK, BLANK, 0 },
        { WALL, WALL, WALL, WALL, WALL, SCORE, WALL, BLANK, WALL, WALL, WALL, HOLE, WALL, WALL, WALL, BLANK, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, 0 },
        { BLANK, BLANK, BLANK, BLANK, BLANK, SCORE, BLANK, BLANK, WALL, BLANK, BLANK, BLANK, BLANK, BLANK, WALL, BLANK, BLANK, SCORE, BLANK, BLANK, BLANK, BLANK, BLANK, 0 },
        { WALL, WALL, WALL, WALL, WALL, SCORE, WALL, BLANK, WALL, WALL, WALL, WALL, WALL, WALL, WALL, BLANK, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, 0 },
        { BLANK, BLANK, BLANK, BLANK, WALL, SCORE, WALL, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, BLANK, WALL, SCORE, WALL, BLANK, BLANK, BLANK, BLANK, 0 },
        { BLANK, WALL, WALL, WALL, WALL, SCORE, WALL, BLANK, WALL, WALL, WALL, WALL, WALL, WALL, WALL, BLANK, WALL, SCORE, WALL, WALL, WALL, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, WALL, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, POWER, SCORE, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, BLANK, BLANK, BLANK, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, SCORE, POWER, WALL, BLANK, 0 },
        { BLANK, WALL, WALL, SCORE, WALL, SCORE, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, WALL, WALL, SCORE, WALL, SCORE, WALL, SCORE, WALL, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, WALL, SCORE, SCORE, SCORE, WALL, WALL, WALL, SCORE, SCORE, SCORE, WALL, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, SCORE, WALL, WALL, WALL, WALL, WALL, WALL, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, SCORE, WALL, BLANK, 0 },
        { BLANK, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, WALL, BLANK, 0 }
    };

    int i;

    for(i=0; i < MAX_Y; ++i)
        memcpy(&vp[i], init_view[i], MAX_X + 1);
}
Back to top
tienkhoanguyen
PSEUDOCODER


Offline
Joined: 05 Sep 2014
Posts: 2664
Location: Texas

PostPosted: Wed Dec 31, 2014 10:48 pm     Post subject: God, Cheese-its & Rice, is number one!hehe Reply with quote

Cheese-its & Rice!hehe

Okay, Heaven. Here I go, hehe. This is my remake of "Ball and Paddle" game. It is extremely slow for the little kids. You can use either the keyboards or the gamepads.

The keyboard controls are:

A-left
D-right

J-left (other player)
L-right

It is better to buy one of each of the following controllers:

Microsoft XBOX360 controller with USB connector
SONY PlayStation controller with USB connector adapter

Please talk with Quadko on this website if you need info on the controllers.

So this is my game for The New Year 2015

As the pirates say, "Enjoy!" hehe

http://www.mediafire.com/download/uqo4jxbo2380w8x/BALLPADL.EXE
Back to top
tienkhoanguyen
PSEUDOCODER


Offline
Joined: 05 Sep 2014
Posts: 2664
Location: Texas

PostPosted: Wed Dec 31, 2014 11:17 pm     Post subject: God, Cheese-its & Rice, is number one!hehe Reply with quote

Cheese-its & Rice!hehe

Well, I'll be. Here is a Windows version of the same game hehe. For those of you who think the DOS version is just too slow...

http://www.mediafire.com/download/2nhwdc0bfcbjqdq/ballnpad.exe
Back to top
tienkhoanguyen
PSEUDOCODER


Offline
Joined: 05 Sep 2014
Posts: 2664
Location: Texas

PostPosted: Thu Jan 01, 2015 1:11 am     Post subject: God, Cheese-its & Rice, is number one!hehe Reply with quote

Cheese-its & Rice!hehe

I think this ball and paddle game is called pingpong? I am not too sure about the English language since I am Vietnamese. However, in this second edition of this remake, I made it so that you scored a point as a team every time the paddle reflects the ball. It just so happens that it is something young kids could play. I remember starting games at least around 9 years old.

http://www.mediafire.com/download/uqo4jxbo2380w8x/BALLPADL.EXE
Back to top
Display posts from previous:   
Post new topic   Reply to topic    DOS Games Discussion Forum Index -> Game Creation All times are GMT - 5 Hours
Goto page Previous  1, 2, 3
Page 3 of 3

 


Powered by phpBB © 2001, 2005 phpBB Group and Ask an Expert
Also powered by Darren and the other admin and mods' hard work! ;)