Steam 설치
로그인
|
언어
简体中文(중국어 간체)
繁體中文(중국어 번체)
日本語(일본어)
ไทย(태국어)
Български(불가리아어)
Čeština(체코어)
Dansk(덴마크어)
Deutsch(독일어)
English(영어)
Español - España(스페인어 - 스페인)
Español - Latinoamérica(스페인어 - 중남미)
Ελληνικά(그리스어)
Français(프랑스어)
Italiano(이탈리아어)
Bahasa Indonesia(인도네시아어)
Magyar(헝가리어)
Nederlands(네덜란드어)
Norsk(노르웨이어)
Polski(폴란드어)
Português(포르투갈어 - 포르투갈)
Português - Brasil(포르투갈어 - 브라질)
Română(루마니아어)
Русский(러시아어)
Suomi(핀란드어)
Svenska(스웨덴어)
Türkçe(튀르키예어)
Tiếng Việt(베트남어)
Українська(우크라이나어)
번역 관련 문제 보고
The best way to learn is to understand. Look at example snippets and try to understand why they are doing what they are doing. Google-Fu is your biggest weapon.
I disagree (apart from that Hungarian notation is evil, which it is); especially if you're talking about a relatively conservative language like C++, best practices don't evolve that quickly to make a relatively recently written (or updated) book obsolete (it's still a bit iffy, given the platforms we have to support, to adopt C++14 features at work. Lord knows when it'll be safe for us to adopt C++17...), and what a decent book can do that that examining random snippets can't is give you a holistic overview. A decent C++ book will tell you about things like the rule-of-five (née rule-of-three) which are pretty tricky to pick up from reading example snippets.
You're also just at risk of picking up bad habits from random examples. As an example: older code will tend to make heavy use of raw pointers; modern code should use std::unique_ptr or std::shared_ptr instead. Or using C-style arrays when you could/should be using a std::array. And so on.
What's wrong with iterators? The modern range-based for is, after all, syntactic sugar over iterators. The only real problem to my mind was their ludicrously complex types, which is solved by 'auto', and the aforementioned ranged-based for means you get the benefits without even having to worry about that.
To my mind, the major disadvantage of books is that they cost money, and your average community library isn't generally well-stocked with up-to-date programming books.
Personally, I'd say the best way to learn is a little of all of the above. A book will provide solid theoretical background, but it's just as important to write stuff yourself to help practice what you're learning from the books, and you can supplement that with looking at and understanding other people's code.
I would definitely not start by aiming at a game engine; 3D graphics is not a simple thing by itself, so setting yourself up trying to learn two complex things simultaneously is a really good way to set yourself up for failure.
THouugh honestly if your goal is game development. I might actually suggest some game devbelopment tools. RPG Maker, Games Workshop, etc.
GAme development is a lotr more than nuts and bolts coding these days and learning to use these tools will give you a chance to learn about how 'you want to design games' From there you can decide what languages you'll need to compliment your prefered approach.
I can also recommend playing around with games that have their own editors. They tend to be more limited buyt again they will teach you the lines of thought needed for game development.
You could also check out the source engine and stuff like Gary's Mod.
Nothing. But the way some people use them is cringe worthy. I've come across several examples from what I'd call an experienced Java developer who uses them instead of a simple enhanced for loop. It just bloats your code and doesn't add anything. And in those cases, they're not even typed checked.
Vs.
Syntactic sugar? Of course! But sooo much more readable. Especially if the doStuff involves leel four nested coded in itself.
And that's really what I meant.
Start small and go forward in small increments.
* Learn how to display text to the user.
* Learn how to change this text based on user input.
* Learn how to display graphics.
* Learn how to play sounds.
* Learn how to differenciate sound and graphics based on state.
Baby steps.
As an example my first "more complex game" was written in these steps:
* display character
* make character face up/down/left/right
* make character move up/down/left/right in a 3x3 grid
* make character respect borders of the 3x3 grid
* display walls in a 9x9 grid
* display walls in the middle of the 9x9 grid
* make character respect walls in the middle of the 9x9 grid
* display objects in the world
* make character collision with object in the world
* make character interact with object next to it
...
and suddenly you have the base of a rogue-like.
Or a CCG:
* display card
* display board
* display board with cards
* display hand
* move card from hand to board
* display energy
* make card cost engergy to play
* display two players with health
* make card attack other player and deal damage
* make card intercept other card from dealing damage to player and allocate damage to intercepting card instead
* make card react to damage
... HearthStone clone in the making.
---
Learning a programming language is no different to learning a natural language. You have to learn basic vocabulary and grammar. Then learn to express concepts with it.
"Hello World" is no different to "I am cinedine", "Ich heiße cinedine", "Mi chiamo cinede".
"Hello, <user name>" is no different to "Who are you?", "Wie heißt du?", "Come ti chiami?".