Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 10 Jan 2001
Offline Last Active Sep 12 2014 01:02 PM

#5142074 Scripting! What to script/what to not script?

Posted by on 25 March 2014 - 01:23 PM

Usually, the game engine is in C++ and all the game specific stuff is scripted (especially the AI).

#5002727 [C#] Getting ray from mouse position

Posted by on 20 November 2012 - 01:11 PM

What's transform.position? If it's not the camera position or ray origin, then the direction won't point to where you clicked. And by the way, I think it would be better to give an impulse to your bullet by setting its velocity directly instead of using AddForce.

#5000308 Google page flipping animation

Posted by on 12 November 2012 - 01:55 PM

I suppose it's just a pre-made animation and the current frame is set in function of the position of the finger. I really don't think there's any physics modeling behind this, but I may be wrong.

#4996201 Question on boost::shared_ptr

Posted by on 01 November 2012 - 08:49 AM

You should only use shared_ptr for dynamically allocated objects (allocated with new)! You are passing the address of objects created on the stack, that's why it crashes.

#4993777 Want to program for big developer. what should i be learning?

Posted by on 25 October 2012 - 07:02 AM

Major strategy failure. Neither a Bachelor’s nor Master’s degree will help you in the least, and can in fact hurt you.

Don't listen to this!!! I don't know where L. Spiro is from, and maybe this tip is good for his/her isolated place on earth, but I know for sure that here in Montréal, where the gaming industry is big, they will never hire a programmer without a Bachelor degree. He's right for the master's degree though.

#4993148 Template and containers question

Posted by on 23 October 2012 - 11:35 AM

Well, you can use template specialization, but at that point, I would just not use template at all and add a function for every type of callback, such as:

[source lang="cpp"]void RegisterCallback(const KeyCallback& ev);void RegisterCallback(const MouseButtonCallback& ev);...[/source]

#4988322 Reading wrong values from Joystick for the first few milliseconds

Posted by on 09 October 2012 - 06:42 AM

I'm not sure if it's the cause of the problem, but the first call to joyGetPosEx is done with an uninitialized structtmp structure. From the documentation, that's illegal and the call should fail.

#4984056 C++ and OpenGL

Posted by on 26 September 2012 - 12:29 PM

If you want to really make a game, start with an existing engine. If your goal is to play with OpenGL and C++ and probably never ship a real game (unless it's a really simple one), then go that way. That's my advice.

#4980070 Web developer or Software developer

Posted by on 14 September 2012 - 08:42 AM

Maybe I'm wrong, but I think that web developers are just a subset of software developers. As a software developer, you can always specialize in web.

#4977659 Passing references around internally in the engine

Posted by on 07 September 2012 - 08:59 AM

Oh well, you're right L. Spiro. It was early, I shouldn't have answered this question as I didn't even understood it correctly... sorry!

#4977599 Passing references around internally in the engine

Posted by on 07 September 2012 - 06:32 AM

You should probably have a kind of singleton manager, responsible for the creation and destruction of all singletons, instead of putting them in other classes. They should be pointers instead of plain member variables. That way, you'll be able to control creation and destruction order. I'm not sure if I understood your problem correctly though...

#4975121 Collision with polygon or Polyeder

Posted by on 31 August 2012 - 06:30 AM

The separating axis theorem will tell you if your objects collide, but not where. Then, if you need the exact point(s) of collision, you'll have to check with every face.

#4969841 How to check for UI mouse events properly

Posted by on 15 August 2012 - 08:25 AM

Send your mouse event to the UI first and make the UI return a true/false value if it handled the event or not. If not, send the event to the game code.

#4969509 I'm pretty much starting out, just looking for validation/tips.

Posted by on 14 August 2012 - 09:57 AM

You don't necessarily have to learn C++ to have control on what you do. No offence, but with your current level of programming skills and by learning C++ in your spare time, it will take years before you can make a game from scratch!

What I would suggest is to start using a game engine such as Unity. You can get good results pretty quickly. The skills you'll learn that way will be a lot more useful to a future game designer than learning how to program in C++. Most game designers have a basis in scripting languages, but the vast majority don't know C++ and will never have to know it.

If by designer you mean programmer (which is not the same at all), then learning C++ can help, but as I said before, it'll take a really long time before you get good results without using an existing game engine.

So, my advice is to use an existing engine. You'll touch programming and design concepts, just like what you want to do, but you won't be overwhelmed by the gigantic task of creating something from scratch.

#4969413 I need a jumpstart

Posted by on 14 August 2012 - 05:51 AM

I think that your two questions have a similar answer: it depends on what you want to do. I think that using an existing engine such as Unity is a good way to start, because it will teach you the architecture of modern game engines and you'll be able to have great results pretty quickly. You'll learn how things work in a game. That is a great thing, especially if you would like to become a gameplay/AI programmer. These programmers rarely touch low level stuff, so everything you learn will be valuable in almost any engine. You'll have to deal with linear algebra, some graphics concepts and AI.

If you want to become a game engine programmer, I would still suggest to use a complete engine like Unity first, to at least know how things are done. Then, you can use intermediate libraries like SDL or XNA to create your own engine.

Learning OpenGL or DirectX is not necessary. I'm a professional generalist programmer in the industry since 2003 and I almost never had to touch the low level graphics libraries. It a good thing to know how they work though, but you don't necessarily have to be a power user, unless you want to become a 3D/graphics programmer.

Like I said, I'm a generalist programmer. Before working in the industry, I never made a complete game. I made a huge amount of small programs using a lot of different libraries (graphics, sound, input, physics, etc.). I even tried to make my own game engine and physics engine. I learned a lot of stuff doing that. So, I would say that the paths to work in the game industry are multiples and they depend on your interests and goals. If you really like graphics, you can specialize yourself in that area and just do that, you may have the chance to become a 3D programmer later. But as a tip, at least were I work, the majority of job openings are as gameplay programmers, so you are probably better to just start using a game engine first.

I hope this helps!