Allegro.cc - Online Community

Allegro.cc Forums » The Depot » New game I made Capital City

This thread is locked; no one can reply to it. rss feed Print
New game I made Capital City
TinoR
Member #1,343
May 2001

Hi everyone

Here is a story adventure game called capital city.
I made it with allegro and lua I programmed it in c

you can download it on my gamejolt page

https://gamejolt.com/games/Capital_City/308393

below is a youtube video I did for it

Happy New year
hope you guys like the game if you try it

edit: the youtube video link
(i tried embedding it but not sure if it worked
https://www.youtube.com/watch?v=QAvHtgpNRxs

video

Chris Katko
Member #1,881
January 2002
avatar

Wow! Great work! I just watched the trailer I'll try downloading when I can later.

-----sig:
“Programs should be written for people to read, and only incidentally for machines to execute.” - Structure and Interpretation of Computer Programs
"Political Correctness is fascism disguised as manners" --George Carlin

beoran
Member #12,636
March 2011

Nice to see a game made with Allegro. Perhaps you could also make a Linux version for people like me who don't have Windows. Or better, consider releasing the sources of the game under an open source license if you're not planning to sell it.

Eric Johnson
Member #14,841
January 2013
avatar

Nicely done! I got it working on Linux using Wine. I've only played a little bit so far, but I'm having fun! Thanks for sharing!

beoran said:

Perhaps you could also make a Linux version for people like me who don't have Windows.

Have you tried running it through Wine, beoran? wine ./Capital\ City.exe

TinoR
Member #1,343
May 2001

Beoran attached is the source file

All the data for each chapter is in a lua file that is why source isn't that big

I used allegro 4.4 and lua5.1 for libraries

beoran
Member #12,636
March 2011

Thanks for posting the sources. I will try to make a Linux version but it might take a while...

SiegeLord
Member #7,827
October 2006
avatar

Tried it. I liked the sound effects, and in general it seemed to hit all the right 90's adventure game notes gameplay-wise. I didn't get very far though... got stuck in chapter 2.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

bamccaig
Member #7,536
July 2006
avatar

Making a game is a huge accomplishment. I've never done it. For that I am envious. :)

I've spent a little time trying to build it for Linux, but have had little success. It would help if you specified which version of Lua and Allegro you used (it appears Allegro 4, so I don't think it matters which version, but it wouldn't hurt to know).

TinoR
Member #1,343
May 2001

It was written in allegro 4.4 and lua 5.1

If you want game to load with all the chapters unlocked
enter and replace secret(#) with secret(25622) in lua file last_save.lua

bamccaig
Member #7,536
July 2006
avatar

Thanks. I think I got it running.

Makefile#SelectExpand
1CFLAGS = $$(allegro-config --cflags) $$(pkg-config --cflags lua51) 2LIBS = -lm $$(allegro-config --libs) $$(pkg-config --libs lua51) 3 4all: a.out 5 6a.out: 7 $(CC) $(CFLAGS) -Wno-all main.c $(LIBS)

(A.cc eats tab characters so be sure to restore the tab on the last line)

It seems to use a non-standard function strset so I threw this together. You'd need to copy/paste that into main.c for Linux probably (or otherwise compile and link it).

char * strset(char * s, char c) {
    int i;

    for(i=0; i<strlen(s); i++) {
        s[i] = c;
    }

    return s;
}

This code produces a lot of warnings from GCC so I suppressed most of them so I could see what was happening. Nevertheless, it's quite concerning. :P

Go to: