• 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
Krankles

Still not confident in my game programming skills in C++ and SFML

6 posts in this topic

Hi, I made some games in ActionScript 3 and recently switched over to C++ a month ago. I already knew some things about C++ because AS3 is quite similar to it. So I chose SFML as my API to use to create games with.

 

After going through this tutorial: http://www.gamefromscratch.com/page/Game-From-Scratch-CPP-Edition.aspx I learned quite a bit about SFML, but after finishing through it, I still don't feel very confident with using SFML and C++.

 

Can someone lead me in the right direction to make myself more confident with the language and API? Basically what I'm trying to say is, is that when I see C++ and SFML code, I understand it (well, most of it) but when I am trying to create my own, I am braindead, I don't really know what to do.


I am planning to recreate my games I already created in AS3, but of course, there's the barrier of me not being so confident as I was with AS3.

 

Thanks.

0

Share this post


Link to post
Share on other sites

Well, you could start by creating a window. After that, you can make the window display images. Then perhaps animate those images. Then keep adding the features you need. Do things in the order of difficulty, from easy to hard, from simple to complex. You are at least confident that you can make a window, right?

2

Share this post


Link to post
Share on other sites
"I already knew some things about C++ because AS3 is quite similar to it."

That you would say this creates the impression you know practically no C++. These two languages are extremely different.

I think the most crucial question at this point is, what's your motivation in switching languages at this point? Why are you switching into C++ specifically? For most people, if their goal is to just keep developing their own games, C++ is overkill.

I half-agree with Cornstalks' advice. You can use external libraries if you like, but you must put serious attention to learning the features of the core language. One good resource for language detail is Sutter's GotW column: http://herbsutter.com/gotw/

To work effectively with C++, you have to understand and (eventually) remember a large portion of the stuff discussed in GotW. You don't learn it just by reading, of course; you should constantly try the things discussed on your own, and when there are recommendations or best practices, you should adapt some of your existing code to adhere to them. Edited by Stroppy Katamari
0

Share this post


Link to post
Share on other sites

Thanks for the recommendations!

 

Of course I know how to create a window :P I'll try what ultramailman and IkarusDowned are saying. When you break it down like that, it is actually seemingly easy. I think my problem is, is that I need to break things down into simple and easy steps and not stray off from what I need to accomplish in my project.

 

I don't think my C++ foundation is properly laid just yet, I still need a full understanding of pointers, inheriting, etc.

 

Stroppy Katamari, actually I beg to differ, their syntax's are similar, but not exactly the same. Such as creating functions, variables, while loops, for loops, etc. Obviously c++ is more esoteric and has more features/capabilities to it. I did go learn the basics of c++, what I meant when I said "I already knew some things about C++ because AS3 is quite similar to it" is that since I know AS3, learning the basics of C++ wasn't really that hard at all.

 

Anyways, Sutter's GotW is actually very, very helpful. If you have any more of these kinds helpful links, I will appreciate it.

0

Share this post


Link to post
Share on other sites

I would say that you are right, in fact you didn't learn only a language (AS3), you learned imperative programming. which in any language of this paradigm, will break down to the exact same things and concepts (loops, ifs, functions..). Why, because the CPU is doing so.

There are other paradigms, like functional programming (lisp..), and logical programming (prolog..). Both have different way of thinking the program design/execution flow.

But indeed, knowing AS3 made you know C++, somehow. Of course, while this is true, it is also false because after the paradigm, there is all the rest: software engineering. And that one, is the big one. It takes a few weeks to master the imperative programming paradigm, it takes a few decades to master software engineering.

C++ is the one language that has all, or almost everything, and is also the one language that can actually not be mastered. Even the persons writing the standard are discovering new rules, new patterns, new ideas, new smells, new pitfalls, new must-not-do, on a monthly basis... and it is a real never ending live feed to learn programming (in C++ particularly).

 

So good luck on your way with that, I know I love that adventure.

GotW is a bit hard at first, I would recommend programming on yourself a bit, shooting yourself in the foot, you tend remember better things like that :)

After, you can go back to read the C++ faq lite and GotW as much as you want, and agree as an equal thinker to the great minds that wrote it. But going as a beginner, you will only be able to say "oh really, hmm, ok then I'll take the advice". Its funnier to have the experience to actually having come up yourself with what is said in those Faqs/GotW.

You will notice on those pedants sources, that the standard is mentioned quite a lot. It is actually a good thing to DO read it. However, the 2003 version is around 800 pages, the 2011 is around 1800 pages (or 1600?). It is a brain twister, it is like reading the civil code book. And if you are not native in english it is even more difficult.

But please, about this, take my advice : the very C++ standard paper, is a much better source than any book and tutorials/resource found on the net written by average Joe. Because more often than not, people who think they can go teach others, only learned through compiler reporting; which is a bad way, especially when that compiler is from microsoft.

but anyways.

 

If you have difficulties at planning the tasks, don't worry, it is actually full time job for many people in this world. And to do it, it requires to know what is possible, and how it is possible also, at last on a vague latent zone of your brain. You have difficulty planning things when you are too unsure about the way to do achieve it.

For example, if you want to draw a 3D rotating cube, and when you think about how to start, and you can't come up with anything, it is because you don't know how to do it yet. So you need to start draw 2D things instead, and suddenly things are getting clearer "ah yes, I know drawing a thing is drawing pictures or sprites, I know pictures because I have manipulated them in paint or so". You want to make it cross the screen "ah yes, I know I can use a loop to increment a position variable and draw at each iteration". Because you have imperative programming knowledge.

Just continue on this path and one day you'll arrive "Ah, the 3D cube, now I know i need a representation of the vertices in memory, a model matrix and a projection matrix, I need a line drawing routine, and maybe a timer to adjust the rotation speed..." etc etc

 

so just do like the others said, tic tac toe etc...

One last word, about SFML, it is actually a good library to start with because it has a good C++ design. If you had started with OpenGL for example, it would have taught you old C-style design.

 

good luck

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