Giter VIP home page Giter VIP logo

tetris-sdl-c's People

Contributors

dashed avatar oxore 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tetris-sdl-c's Issues

haiku

is possible to port to haiku?

The game instantly closes on macOS Big Sur

I followed the instructions but when I go to run Tetris-toy it instantly closes, here is what terminal said:

`Last login: Sat May 22 10:45:04 on ttys000
/Users/dylanevans/Downloads/tetris-sdl-c-master/tetris_toy ; exit;

The default interactive shell is now zsh.
To update your account to use zsh, please run chsh -s /bin/zsh.
For more details, please visit https://support.apple.com/kb/HT208050.
Dylans-Air:~ dylanevans$ /Users/dylanevans/Downloads/tetris-sdl-c-master/tetris_toy ; exit;
objc[2587]: Class SDLApplication is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbce38) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0618). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLAppDelegate is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbce88) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0668). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLTranslatorResponder is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbcf00) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e06e0). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLMessageBoxPresenter is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbcf28) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0708). One of the two will be used. Which one is undefined.
objc[2587]: Class SDL_cocoametalview is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbcf78) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0758). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLOpenGLContext is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbcfc8) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e07a8). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLWindow is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbd018) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e07f8). One of the two will be used. Which one is undefined.
objc[2587]: Class Cocoa_WindowListener is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbd040) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0820). One of the two will be used. Which one is undefined.
objc[2587]: Class SDLView is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbd0b8) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0898). One of the two will be used. Which one is undefined.
objc[2587]: Class METAL_RenderData is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbd108) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e08e8). One of the two will be used. Which one is undefined.
objc[2587]: Class METAL_TextureData is implemented in both /usr/local/lib/libSDL2-2.0.0.dylib (0x10adbd158) and /usr/local/opt/sdl2/lib/libSDL2-2.0.0.dylib (0x10b1e0938). One of the two will be used. Which one is undefined.
tetris_toy(2587,0x202dece00) malloc: *** error for object 0x7fa180963e10: pointer being freed was not allocated
tetris_toy(2587,0x202dece00) malloc: *** set a breakpoint in malloc_error_break to debug
Abort trap: 6
logout
Saving session...
...copying shared history...cp: /Users/dylanevans/.bash_history: Permission denied

...saving history...-bash: /Users/dylanevans/.bash_history: Permission denied
truncating history files...
...completed.

[Process completed]

`

thanks for reading :)

clean up code smells

Some code smells:

  • variable naming and init placement
  • method naming
  • global var clean up

cant compile it on arch linux

tetris-sdl-c/src/init.h:6:multiple definition ofwindow'; init.o:/tetris-sdl-c/src/init.h:6: first defined here
tetris-sdl-c/src/init.h:7: multiple definition of render'; init.o:/tetris-sdl-c/src/init.h:7: first defined here tetris-sdl-c/src/input.h:4: multiple definition of TETROMINO_ACTION'; input.o:/tetris-sdl-c/src/input.h:4: first defined here
collect2: error: ld returned 1 exit status
make: *** [makefile:17: tetris_toy] Error 1

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.