How hard would it be to...

Started by
7 comments, last by 3Ddreamer 10 years, 3 months ago
Convert win32 and fixed function directx code to Allegro 5/fixed function OpenGL? I wanna read "Programming Role Playing Games with DirectX" by Jim Adams but def do not want to use the outdated Win32/DX8 code.
Advertisement

Does it matter? It's a book, I'm assuming that means you're using it for learning. In that case it seems like in order to actually learn the lessons the book teaches you should at least follow along what the code is doing logically, even if you don't feel like testing it yourself.

If you really want to convert the code for whatever reason, the question is still a bit illogical, were you going to not do it if its hard? If anything trying to convert it would probably be a very good way to reinforce the concepts, but, I personally wouldn't do it because on the other hand it will be a massive distraction to be looking up and converting all the code to try and recreate everything.

Converting it to allegro would probably involve, if anything, dropping most of the win32 code since I believe allegro wraps window creation like most other basic frameworks do, you'd probably just have to deal with getting input and such from allegro instead of the pure message queue. Converting to opengl would be.. a bit more challenging, it'd take a lot of reading unless you're already familiar with the graphics concepts and know what you need to look for the equivalent of in opengl.

"How hard is it"? Is that what you're really asking? Nothing is easy!

-- Tom Sloper -- sloperama.com

"How hard is it"? Is that what you're really asking? Nothing is easy!


Of course Tom. But I want to know if its feasible for a relatively inexperienced person like me

Shouldn't be that hard. With graphics libraries, the terms are the same but the implementation is different. So if he uses a term that's alien to you, just google "[term] Allegro 5" and see what comes up. It will be tedious, though. Good luck.

Why don't you just find an OpenGL book, if that is your only reason?

Stay gold, Pony Boy.
My reason is to code an rpg but I dont want to use the decade+ old sdk that is being used in the book

What's your general level of experience with programming? Do you know any OpenGL or Direct3D (any version) currently?

I'm not familiar with the book, so I don't know how well the author has separated the game logic from the rendering code. If they've done a decent job at that, then the systems should be relatively easy to extract (e.g. movement, scripting, UI, Inventory) if not essentially copy-paste-able. For rendering, you probably need at least some familiarity with both APIs in order to re-map concepts from Direct3D to OpenGL. If they've done a poor job at separating rendering, it's probably not worth trying to port the code, but the book might still hold some value from a general standpoint of illustrating the kinds of engine components and RPG requires, and how they fit together.

You'll also face some other issues due to the age of the book: Most pressingly, fixed-function in general is dead (not just for DirectX), and the C++ language has moved on. If you want to learn modern best-practices, you might be better off picking up a modern C++ text, a modern OpenGL/DirectX text, and using the RPG book mostly for ideas on how to build the game logic. But all that probably requires a fair bit of grounding in programming.

throw table_exception("(? ???)? ? ???");

Hi,

You have many other more important things to learn at these stages of your learning and game development. In my opinion this is worse than a bunny trail. This is really wandering from other things that should be getting your hard work and long hours at this time.

Personal life and your private thoughts always effect your career. Research is the intellectual backbone of game development and the first order. Version Control is crucial for full management of applications and software. The better the workflow pipeline, then the greater the potential output for a quality game. Completing projects is the last but finest order.

by Clinton, 3Ddreamer

This topic is closed to new replies.

Advertisement