• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.
Sign in to follow this  
Followers 0
Genocode

Newbie programming question (AS3 draws to "stage" as C++ draws to "?")

8 posts in this topic

Hello people. Um...I'm a bit new and have been learning programming in Flash Actionscript 3.0 for some time. I dont know too much about Java and C++ (...yet) but I've noticed that the overall structure of how code is put together in Java and C++ seems somewhat similar and I've been looking into expanding/graduating to C++ or Java in the future. I've noticed that flash comes with a stage element that pretty much provides a place to blit sprites and graphics on to. This is probably a stupid question but I wanted to know if there was something similar to that in Java or C++ or just generally any other language that doesn't come with a 'stage' element like flash does. If so, how would it be done?
0

Share this post


Link to post
Share on other sites

So in order to get images on screen I would need to use a library like the ones you've listed that facilitate the process. I asked about this on another forum and realized that flash seems to be designed for visual purposes almost exclusively so naturally they provide a stage element for easy drawing. Thanks for the clarification.

 

I also hear that C++ is something you learn for a long time before you can get very good at it. Is Python a good pitstop along the way?

0

Share this post


Link to post
Share on other sites
If you want to learn C++ then start studying C++. It has some complex interactions, but it's not hard to learn the basics, and from there to begin the process of improving your skill. Python is not a bad language, but don't think that you should use Python as a stepping-stone for C++. It's like a screwdriver and a hammer. You don't have to learn one in order to qualify yourself for the other.
0

Share this post


Link to post
Share on other sites

The two languages aren't really comparable in that  way. AS3 is a high-level language, with very abstracted graphics drawing. If you're after a gentle transition from AS3 to something else, I'd suggest Java over C++ as its more similar (though, probably not quite as useful in the long run) and OpenGL. If you have an Android device, Java and OpenGL ES is a lot of  fun to learn. I'd also suggest OpenGL ES2 over OpenGl 1.x as well, because its almost the same standard as WebGL and writing your own shaders is a useful life-skill. I'm sure what I just said is probably a  lot to  take in, but just do some research  into the things I just mentioned and it might help you decide where to go next. I've been a Flash programmer for a couple of years and have been transitioning to other languages to make games and this was a comfortable road for me. Of course, if you're just trying to make a game as quickly as you can, Unity is a pretty neat engine with a lot in common with Flash.

0

Share this post


Link to post
Share on other sites

Thanks for the suggestions! I actually could understand what you said quite well (...probably). I've been slowly wrapping my head around flashes stage3D and its relation to the GPU pipeline so I think I have an idea of what you mean with shaders. Right now Im dealing with 2D games so its not so much a big deal performance wise. But ultimately I will want to do 3D programming. I'll stick with flash awhile longer until I know I need to upgrade for the extra processing power. I'll keep track of the progress of each languages libraries in the mean time.

0

Share this post


Link to post
Share on other sites

If Java and OpenGL ES on an Android embedded device looks like a little too much of a learning curve for you from AS3 2D drawing, perhaps have a look at C++ and SDL. That way you can learn the C++ language in an easy manner without being bogged down unnecessarily with platforms and technology.

Then when you are ready for 3D, you can still use SDL but then also start looking at some examples of how to use it with OpenGL.

 

Remember, just because C++ allows you to do pretty technical stuff which is close to the hardware, it doesnt mean you have to. There are loads of libraries that are as high level and simple (or simpler) as those found in Java and AS3.

 

As an aside, I personally find OpenGL with C++ a lot easier than doing it with Java since Java's Garbage collection system doesn't really work with memory stored on the graphics card whereas C++'s RAII works great. Also converting java arrays into a format suitable for uploading to the graphics card is pretty awkward.

Edited by Karsten_
0

Share this post


Link to post
Share on other sites

a few random comments:

while syntactically, AS3 is closer to Java, in some areas its semantics and language features are actually a little closer to those in C#.

 

granted, others may disagree.

 

the Flash APIs are fairly specific to Flash though, and likewise some AS3 features don't map exactly to the other languages.

 

 

as for GC:

yes, for a lot of problem domains it kind of gets in the way, and getting good performance out of Java may involve some level of ugly and convoluted code.

also, while it tries to infer the lifetime of objects to release them early, this requires some care to utilize effectively (basically: don't store it anywhere outside of local variables or newly created temporary objects, otherwise it will become part of the global heap and typically wont be cleaned up until the next GC pass).

...

 

 

my vote is probably mostly for investing the effort in learning C++, though this may not be an ideal choice if one is intending mostly to target Android or a web-browser or similar (can be done, just there is a lot of "hair" in these areas...). for Android or for web-browsers, Java is a little better.

 

if going cross-platform (and developing traditional games or applications), C or C++ is probably preferable IMO.

 

 

personally... I mostly just use C... but this is mostly for personal reasons (often with a fair bit of custom tools and infrastructure, so isn't really raw C by itself for the most part, *1). otherwise, at this point, I would probably more likely go with C++.

 

*1: note: using C does not necessarily mean being limited to writing procedural-style code (what the language provides built-in is secondary to what can be done in the language, and actual development practices may diverge considerably from what many people seem to assume it implies, ...). all this has turned into big pointless arguments in the past, which is not my point here.

 

 

a personal dislike about Java is that vs the relative freedom of C and C++, it is can be fairly constraining.

granted, it can also be noted that this is one of the areas that makes it commonly viewed as making it easy to learn.

 

as far as relative programming freedom and expressiveness, I prefer C# a little more than Java, but its "general portability" is a little weak on many targets (vs Java or C or C++). it is pretty solid if it is reasonable that the code not really be highly portable (IOW: Windows and maybe traditional Linux distros, with 3rd party tools for other targets). some of its features can still be a little annoying to someone who is more used to C or C++ development though (as well as there being a few seemingly arbitrary language restrictions).

 

 

sadly though, there are no "perfect" languages...

mostly just relative tradeoffs...

1

Share this post


Link to post
Share on other sites
Thanks everyone. You've given me a well of information to think about moving forward. Much appreciated.
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0