![]() |
|
Allegro 5 Book |
AleX-G Squadron
Member #13,593
October 2011
![]() |
Hi! www.anothergames.com |
bamccaig
Member #7,536
July 2006
![]() |
The display may be NULL, otherwise the given display is treated as the parent if possible.
-- acc.js | al4anim - Allegro 4 Animation library | Allegro 5 VS/NuGet Guide | Allegro.cc Mockup | Allegro.cc <code> Tag | Allegro 4 Timer Example (w/ Semaphores) | Allegro 5 "Winpkg" (MSVC readme) | Bambot | Blog | C++ STL Container Flowchart | Castopulence Software | Check Return Values | Derail? | Is This A Discussion? Flow Chart | Filesystem Hierarchy Standard | Clean Code Talks - Global State and Singletons | How To Use Header Files | GNU/Linux (Debian, Fedora, Gentoo) | rot (rot13, rot47, rotN) | Streaming |
AleX-G Squadron
Member #13,593
October 2011
![]() |
I cannot understand it. I am not a native English speaker. www.anothergames.com |
Arthur Kalliokoski
Second in Command
February 2005
![]() |
I had to try it myself. 1#include <stdio.h>
2#include <allegro5/allegro.h>
3#include <allegro5/allegro_native_dialog.h>
4
5
6int button;
7
8int main(int argc, char **argv){
9 button = al_show_native_message_box(
10 0,
11 "Warning",
12 "Are you sure?",
13 "If you click yes then you are confirming that \"Yes\""
14 "is your response to the query which you have"
15 "generated by the action you took to open this"
16 "message box.",
17 "Yessir!|Nossir!",
18 ALLEGRO_MESSAGEBOX_YES_NO
19 );
20
21 printf("button was %d\n",button);
22 return 0;
23
24}
The separator bar is part of the string, and the function looks for that and splits the string into two parts I suppose. They all watch too much MSNBC... they get ideas. |
AleX-G Squadron
Member #13,593
October 2011
![]() |
Where is the Yes sir! and No sir! 1#include <allegro5\allegro.h>
2#include<allegro5\allegro_native_dialog.h>
3
4int main (void)
5{
6 ALLEGRO_DISPLAY *display = NULL;
7 al_show_native_message_box(display, "123Hello World!", "3.8 Hello!", "How are you today?", "Hello|World", ALLEGRO_MESSAGEBOX_OK_CANCEL);
8 return -1;
9 if(!al_init())
10 {
11 al_show_native_message_box(NULL, NULL, NULL, "Error", NULL, NULL);
12 return -1;
13 }
14
15}
www.anothergames.com |
Arthur Kalliokoski
Second in Command
February 2005
![]() |
{"name":"606466","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/2\/6\/2604ad0e4d8ffc1399f33a672bf52ceb.png","w":351,"h":259,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/2\/6\/2604ad0e4d8ffc1399f33a672bf52ceb"} They all watch too much MSNBC... they get ideas. |
AleX-G Squadron
Member #13,593
October 2011
![]() |
{"name":"295r6f8.png","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/2\/7\/2705e6abbefbe570283fe8b47bbdddb8.png","w":1281,"h":418,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/2\/7\/2705e6abbefbe570283fe8b47bbdddb8"} www.anothergames.com |
Arthur Kalliokoski
Second in Command
February 2005
![]() |
AleX-G Squadron said: It doesnt show on mine. Very weird. Is there anything to do with visual studio 2012? I don't have a clue, I don't use it. Anyone? Quote: How can i add coding and image tags on here? {"name":"606468","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/a\/0\/a03938535080105763dfcac1fe62f3cd.png","w":472,"h":149,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/a\/0\/a03938535080105763dfcac1fe62f3cd"} They all watch too much MSNBC... they get ideas. |
Trent Gamblin
Member #261
April 2000
![]() |
I think the dialogs on Windows will only use names based on the last parameter (YES_NO). Winapi is a pain and the easy messageboxes don't allow changing those, and nobody wants to code a full fledged one.
|
AleX-G Squadron
Member #13,593
October 2011
![]() |
Is it some kind or bug? www.anothergames.com |
Arthur Kalliokoski
Second in Command
February 2005
![]() |
AleX-G Squadron said: Is it some kind or bug? Trent meant nobody's bothered to write an entire modeless dialog box framework for the odd case where somebody wants multiple buttons with custom text. When you get up to speed in Allegro, write one yourself for fame and fortune! OTOH, you might simply add a modeless dialog yourself with an #ifdef WINDOWS #elif section. They all watch too much MSNBC... they get ideas. |
AleX-G Squadron
Member #13,593
October 2011
![]() |
Ok, i got it. Anyway it is a bit weird it doesn't work. www.anothergames.com |
Thomas Fjellstrom
Member #476
June 2000
![]() |
I don't think you can change the strings for the buttons on some Windows dialogs. So its not a bug in allegro. Just a feature allegro exposes but windows doesn't. -- |
AleX-G Squadron
Member #13,593
October 2011
![]() |
Looks like the book will be bigger than expected. I reached page 40 and still on the chapter text and fonts. It is 2:03 AM on here, so i am working very hard on this book. Hope anyone got any ideas or some diagonal text programming I have a big question. What is a backbuffer? www.anothergames.com |
Specter Phoenix
Member #1,425
July 2001
![]() |
AleX-G Squadron said: I cannot understand it. I am not a native English speaker. Okay, so your book will either be for a narrow non-English speaking audience or if you do it in English it will be possibly confusing at times due to, you yourself, saying your English is poor due to it not being your native language? Also, there was a book written back around Allegro 3.1.x and the author of that himself said Allegro didn't have a large enough of a following to warrant a new book for it. He said it was a niche library that no company would or could justify publishing a book about it. To me, Allegro is for programmers, by programmers, and programmers that can't understand the manual or what it means shows how much more the programmer needs to improve. AleX-G Squadron said: My question is: allegro 5 book. Any? NO! Epic fail.
A5 Book. Any? NO! Reason: no one would read the stupid thing (ask Harbour, his A3 book only sold due to starry eyed programmer wannabes). AleX-G Squadron said: 1)Installing Allegro Each one of those could be an article on the wiki as a wiki is, in a sense, just a large table of contents with a search feature to help find the articles(chapters) you need. AleX-G Squadron said: Does the manual tell me how can i make 2 doors that teleport the player? That has nothing to do with Allegro at all. The only thing Allegro would be doing in that case would be handling events, input, and displaying the doors and player. Otherwise that would be reliant on your abilities with the language you are using and math/physics skills. Nothing you have mentioned in this thread has justified or warranted a book. Plus, as ML pointed out to Harbour when he did his A3 book, Allegro updates so rapidly that the book would be outdated by the time it was published and released. AleX-G Squadron said: I have a big question. What is a backbuffer? That question just shows you aren't ready or the person needed to write a book about A5 or anything in programming.
|
AleX-G Squadron
Member #13,593
October 2011
![]() |
Wow man, i see you like commercial. www.anothergames.com |
Specter Phoenix
Member #1,425
July 2001
![]() |
AleX-G Squadron said: Wow man, i see you like commercial. Nope, I only use Allegro, played with SFML and SDL and have never touched DirectX with plans to look into OpenGL at a later date. Quote: I just think that allegro can be used for programmers and a book can make a big step. It is used for and by programmers and you are the only one whining about wanting a book for it. Quote:
I even dont want to sell the book. I wrote 40 pages today as i am at page 46. How comes allegro is so fast? A year ago it was version 5.0.5 now it is 5.0.7
What? Quote: I can write the book in a week, that means the book will resist for a lot of time, not because of allegro, but because of people who want money and dont write a book because they are lazy, want to win money fast. Than thanks for paving the way toward success. I see on youtube only mikegeig and coding made easy, which i argued to him about why he didnt make allegro 5 and than he made allegro 5. I'm going to have to call bu||sh!t on that one. He started making those back in February of this year and you waited six months to post about a book? Quote:
Allegro seems to me an easy job man. After all, there is no need even to answer the backbuffer as i already found it and i know what it is. Now i am the right person to write the book i guess. After all, someone said "Go write the book then!" Millions? You'd be lucky if you get 10. Quote: Also, find any grammar error above, if you can. If I can? A blind man could find your errors above! You drop out words, use wrong words, put the word 'even' in the wrong spot in at least two sentences, 'i' should be 'I', I could keep going on just your post from above. Quote: I think the manual has grammar errors as it doesnt make total sense. The grammar errors are in your head. If you can't understand the manual (which looks like every other manual I've ever seen for other libraries) then you definitely need to stick with web development and forget this whole book business as books take time, the faster you write it the more errors and just plain wrong it will be. Quote: Thanks for fireballs and storms attacks again. Fireballs and storms attacks? It is called trying to talk sense into a delusional person. We told John Harbour all this when he did the book that used A3.1.x and he made it, but when it came out no one used it that much because we were onto A3.3.x or such and most of the issues he pointed out in his book was fixed or changed so it was wrong. He still says A3.0.9 is the best Allegro version and refuses to look at A5 because he is in love with Commercial as it helps line his pockets. Books fail because of internet! It is easier to find what your problem is (ie teleporting between two doors) and google it rather than go out finding books that cover that topic. One Allegro book has already failed, all you are doing is writing a second allegro book that will fail. Good luck in that though. Oh, and you need to look at more than the first page of a search or at least more than the first few results. This has at least 3 or 4 different guys by the end of that page that have done allegro 5 tutorials of some sort.
|
Thomas Fjellstrom
Member #476
June 2000
![]() |
Specter Phoenix said: What? Allegro is on 5.1.3 . Sorta. Thats the WIP version. -- |
Specter Phoenix
Member #1,425
July 2001
![]() |
Thomas Fjellstrom said: Sorta. Thats the WIP version. Yeah, I know, but if I remember right Harbour used the latest WIP at the time of writing his book. I try to always use the WIP so I can help find bugs and because of it having the latest bug fixes.
|
Trezker
Member #1,739
December 2001
![]() |
The 5.0 branch is stable, so 5.0.x releases are only for fixing bugs. |
Thomas Fjellstrom
Member #476
June 2000
![]() |
We don't restrict stable releases from getting new features, so long as it doesn't break source or binary compatibility iirc. -- |
weapon_S
Member #7,859
October 2006
![]() |
bamccaig said: then you aren't a programmer. Not you too! AleX-G Squadron said: Help if you want, attack if you can Attacks will most probably be all the help you will get from here, yes. What I mean is: it won't be lovey-dovey fluffed up "suggestions", but hard straight-forward in your face "accusations". And of-course you'll get a little whining nagging as well; that kind of place it is here. |
alehbeer
Member #12,996
July 2011
![]() |
AleX-G Squadron: Please post what you have. You could name it "WIP", as in the expression "Work In Progress", to inform readers that the book is not yet finished. For example: My_Allegro_Book_WIP-version-1.doc Or, you could post it on the Allegro WIKI and people could help you along. Your readers could benefit from the book as it is made. You said you did not like the WIKI, so please help me by improving it. While I know Allegro4 quite well, I am learning Allegro5 at the same time you are. Thank you ahead of time for your contribution to our community.
|
LennyLen
Member #5,313
December 2004
![]() |
When writing an instrucional book (or pretty much anything else), there are two questions you should ask, and have detailed answers for, before you write a single word:
Now, any time you want to add something new, ask yourself "How will this help the people identified in question 2 achieve the goal identified in question 1?" Some of the subject matter you seem to want to add is very situation specific, which means a very minuscule target audience. For such a scenario, a book is not the ideal medium. A guide to making a character teleport, for example, is better suited to an online magazine, a wiki or a youtube video. Information in a book should be as general as possible while still achieving the purpose of the book. I think it would be great to have a book on Game Programming with Allegro 5. I personally like to use books when I'm first learning a new subject matter, then switch to specific tutorials, wikis, and other online references when I've mastered the basics. I'm sure there are a lot of other people out there that are the same.
|
Thomas Fjellstrom
Member #476
June 2000
![]() |
weapon_S said: I certainly don't see myself as a programmer Have you programmed anything? More than one thing? Did it/they work? If the answer to at least two of those things are "yes" then you're probably a programmer. If the answer to all three is yes, then you are most definitely a programmer. -- |
|
|