Giter Site home page Giter Site logo

superjer / tinyc.games Goto Github PK

View Code? Open in Web Editor NEW
319.0 319.0 26.0 19.08 MB

Tiny C games you can compile and run RIGHT NOW

Home Page: http://tinyc.games

License: MIT License

C 98.65% Shell 0.01% Batchfile 0.02% C++ 0.87% Objective-C 0.30% Makefile 0.01% GLSL 0.13%

tinyc.games's People

Contributors

smack0007 avatar superjer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tinyc.games's Issues

WebAssembly/Android/IOS compilation?

Hello, that's an amazing project! I'm learning SDL and searched a lot for a simple, cross-platform barebones SDL sample games made in C, that can be compiled in TCC and uses a permissive license (Such as MIT) yours were one of the few i found. :)

Do you have any plans to add sh scripts for WebAssembly/Android/IOS compilation? Or write/recommend a guide on how these can be done for this specific project? Thank you!

Blocko compiles with a ton of warnings, then crashes when run.

GLGS 4.60, arch linux, gcc 10.1.0.
It says 1st chunk generated, ready to start game, and shows the window and I can see what's in it, but then it crashes with:
GL CALLBACK: ** GL ERROR ** type = 0x824c, severity = 0x9146, message = GL_INVALID_ENUM in glGetIntegerv(pname=GL_GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX)

I can't seem to see where the error is with GDB.

update on tcc 0.9.27

Hi,

first of all, great project!

While playing around with it, I tried to upgrade the libs and the compiler to their most recent releases. SDL2-2.0.9 was no problem, but when replacing the original tcc with its current release, I encounter the following error when trying to run a game:

..\_win\tcc-x64\tcc.exe -DSDL_MAIN_HANDLED -I..\_win\SDL2-2.0.9\include -L..\_win\SDL2-2.0.9\lib\x64 -lSDL2 window.c -run main.c
In file included from window.c:6:
In file included from ../_win/SDL2-2.0.9/include/SDL.h:32:
In file included from ../_win/SDL2-2.0.9/include/SDL_main.h:25:
In file included from ../_win/SDL2-2.0.9/include/SDL_stdinc.h:31:
../_win/SDL2-2.0.9/include/SDL_config.h:68: error: incompatible redefinition of 'size_t'

SDL2-2.0.9 with the original tcc compiler is fine, so it's rather a compiler-related issue.

Have you encountered similar issues and do you by chance know a define that may fix it?

Thanks a lot,
Gerald

Explicitely define which version of the C standard you are aiming at.

Hello,

I would like to know which version of the C standard your code is written for.

Is it ANSI C? C99? C11?

You can use pre-defined macro like __STDC__ or __STDC_VERSION__.

For more information, see:

Best regards.

Windows versions giving errors

Hello,

I'm new to C and SDL and I'm trying to compile the example games on Windows 10 64-bit, but unfortunately, they're failing.

i've git cloned the tinyc.games folder and executed "run.windows" for all the games and they all fail, mostly with the below errors:

Am I doing something stupid?

Thanks for any advice!

C:\tinyc.games\zel>run-windows.bat
..\_win\tcc-x64\tcc.exe
The system cannot find the path specified.
tcc: error: undefined symbol 'SDL_SetRenderDrawColor'
tcc: error: undefined symbol 'SDL_RenderFillRect'
tcc: error: undefined symbol 'SDL_RenderCopy'
tcc: error: undefined symbol 'SDL_SetRenderDrawBlendMode'
tcc: error: undefined symbol 'SDL_RenderPresent'
tcc: error: undefined symbol 'SDL_PollEvent'
tcc: error: undefined symbol 'SDL_Delay'
tcc: error: undefined symbol 'SDL_Init'
tcc: error: undefined symbol 'SDL_CreateWindow'
tcc: error: undefined symbol 'SDL_CreateRenderer'
tcc: error: undefined symbol 'SDL_RWFromFile'
tcc: error: undefined symbol 'SDL_LoadBMP_RW'
tcc: error: undefined symbol 'SDL_SetColorKey'
tcc: error: undefined symbol 'SDL_CreateTextureFromSurface'
tcc: error: undefined symbol 'TTF_Init'
tcc: error: undefined symbol 'TTF_OpenFont'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.