Questions tagged [allegro]

Allegro is a low-level game programming library distributed freely, supporting desktop and mobile platforms. It is coded in C and offers several language bindings.

The latest stable version is 5.0. It is completely rewritten with a new API and full hardware accelerated graphics via OpenGL or D3D. There is official support for Windows, OS X, Linux, and iOS. There is also an unstable branch 5.1.

Links

383 questions
0
votes
1 answer

Enum in multi-file game

I have problem. I have main.cpp file , where is main game, and few header files like CPlayer.h containing classes. In this classes I have animations, and I used enum to replace current animation number with current animation name like: Class…
Barcio77
  • 36
  • 8
0
votes
1 answer

C++ Allegro First Display Program - Translate Rotate Scale

I'm using C++, Allegro5, and codeblocks. I'm trying to write a test program before I write a very basic Asteroids knock-off. The only rules are use C++, Allegro, and no sprites or bitmaps (this specifically has to use primitives like lines and…
TK421
  • 353
  • 2
  • 4
  • 17
0
votes
1 answer

c++ allegro 5 visual studio exception on allegro-5.0.10-monolith-md-debug.dll

I have a problem with allegro that putting allegro-5.0.10-monolith-md-debug.dll in linker input additional dependencies causes an exception, as can be seen in the screenshot. I'm using visual stdio 2013 express.
whatsGravity
  • 71
  • 10
0
votes
1 answer

Allegro can't be linked correctly

Today I installed allegro 5.as the a link. But When I start to write a very simple code. When I compiled using "g++ allegro_test.cpp -o output.out pkg-config --libs allegro5.0" it returns that allegro undefined reference to al install system. When I…
0
votes
1 answer

How to compile atanks from windows?

I'm starting to learn C++ to make a game, I compiled some little programs and it worked fine to learn. Now I want to compile a game and learn how it was done. The game I'm trying to compile is ATANKS (https://libregamewiki.org/Atanks). First problem…
LogoS
  • 313
  • 1
  • 12
0
votes
1 answer

How to declare values of x and y to display it correctly (scaling also)?

Im writing a program in C (using allegro lib) which display points (i could say some sequence) from txt file(two columns X & Y). These are floating points and they can be less than zero. Size of a window is 800x600. As we know values of x increase…
0
votes
1 answer

mysterious crash after load_bitmap from Allegro

I am new to Allegro. We have to use it in our study. I have a problem with my code, which should load a bitmap and print it. #include int main( void ) { allegro_init(); install_keyboard(); set_color_depth(16); …
Zagatho
  • 523
  • 1
  • 6
  • 22
0
votes
1 answer

"Cannot find -lallegro-5.0.4-monolith-mt" Error in Dev-C++ with Allegro

So I downloaded the latest version of Orwell Dev-C++ and managed to run basic text based C++ programs. I downloaded the Allegro 5.0.4 Devpak and installed it using packman.exe. But whenever I try to run code with #include in…
Moss
  • 1
  • 1
0
votes
1 answer

Instaling latest version of Allegro with Code Blocks

In the wiki tutorial http://wiki.allegro.cc/index.php?title=Windows_Vista,_Code%3a%3aBlocks_10.05_and_Allegro_5 I have installed MinGW correctly, but I'm not finding the allegro-5.0.x-mingw-4.a.b folder the libraries should be in.
rvcam
  • 157
  • 5
  • 15
0
votes
1 answer

Allegro Crashes When Loading Bitmap

I've looked around and their are similar questions but the answers haven't fixed my problem. So, the problem is - If i try to load/draw bmp's in allegro it crashes, they are in the same directory as my project, they are named correctly, i believe…
Joseph Smith
  • 3,243
  • 5
  • 20
  • 18
0
votes
1 answer

Allegro not reading all my key presses

I am trying to read keyboard input. I can read 2 keys being simultaneously pressed just fine, but when I try 3, the results differ depending on what keys are pressed. For example, if I press and hold the left array key my sprite moves left. Then…
janovak
  • 1,531
  • 2
  • 12
  • 22
0
votes
1 answer

Allegro al_load_ttf_font can't find file

I've got this short piece of code int main(int argc, char **argv) { al_init(); const ALLEGRO_FONT *arial = al_load_ttf_font("arial.ttf", 12, 0); if ( !( al_init_font_addon() && al_init_ttf_addon() && …
0
votes
1 answer

C++ Allegro Bitmapping Child Classes

I have two child classes which are calling the same parent function. One works fine, but the second call of it can't get past the al_convert_mask_to_alpha line. I'm bamboozled once again. Does anyone know why this may be happening? The function…
0
votes
1 answer

Allegro 4 Functions Errors

I've been learning some game programming with allegro lately and I've run into a problem. My "game" is a compile type of the many tutorials I learnt uptil now. Anyway, I ran into a function problem with Allegro. My first code was this: #include…
Irfan
  • 85
  • 10
0
votes
1 answer

allegro 5 no events work

no events work in my "game" if I test the actions themselves that should happen (like if I put the moving function into the loop itself or the firing function, it works perfectly), but no event works, closing the display, with esc or pressing X, any…
allegroBegin
  • 115
  • 1
  • 10