Jump to content

  • Log In with Google      Sign In   
  • Create Account


Joshhua5

Member Since 26 Oct 2011
Offline Last Active Jul 17 2014 07:44 PM
-----

#5158880 keep all objects in szene in on array

Posted by Joshhua5 on 07 June 2014 - 04:34 AM

With polymorphism you can have it set up like that, you have to hold the pointer to the objects. if you need to use functionality which is present higher in the inheritance of the true object then you have to use a dynamic_cast

 

https://gist.github.com/Joshhua5/33ec4432bf9c04c64715

the program returns 10

 

https://gist.github.com/Joshhua5/d9f87121f33f845d6be9

as an extension of this you can store the pointers in a vector instead.

 

You can learn more here

http://www.cplusplus.com/doc/tutorial/polymorphism/




#5158416 Why do large engines use their own string class

Posted by Joshhua5 on 05 June 2014 - 09:24 AM

While looking through the CryEngine source code I found a file CryString.h

https://github.com/adithedude007/alecmercer-origins/blob/master/Code/CryEngine/CryCommon/CryString.h

 

What I don't understand is why are they creating their own string class instead of using the std::string provided

are there benefits in doing so?




#5151175 Why there no main function in Nehe tutorials?

Posted by Joshhua5 on 03 May 2014 - 06:40 AM

I think you'll find that he changes his code in each tutorial, from the initial creation in lesson 1 which includes the main.

http://nehe.gamedev.net/tutorial/creating_an_opengl_window_(win32)/13001/

all following tutorials most likely inherit this.




#5150004 Becoming a successful game programmer

Posted by Joshhua5 on 27 April 2014 - 08:22 PM

Also having connections with other developers/people, maybe around your age or from a community. People may not say it's as important, but being able to share idea's and experiences will help you if you're having a difficult time for what ever reason. Nothing sells or get's played if no-one knows about it.

 

Obviously this kind of thing comes after you have the ability, but all the comments above are about that.




#5079253 JS logic vs PHP logic

Posted by Joshhua5 on 20 July 2013 - 11:44 PM

I don't have too much experience with either but both come with there cons to my understanding please correct me if I'm wrong.

Javascript :  -Client side, could be edited for an exploit.

PHP:  -Server side, Takes up additional cycles on the server so lots of users would be harder to handle.

          -Page reloading. 

 

Who do you choose?




#5077516 Game message loop - using 50% of CPU when window is minimized or inactive

Posted by Joshhua5 on 14 July 2013 - 12:19 AM

It would be because it's a single threaded program and it max's out one core. if you have a dual core that's 50% usage on your CPU or one core with HT. That's the usual reason.




#5075892 Simple Binary File I/O question

Posted by Joshhua5 on 07 July 2013 - 07:53 AM

try adding std::ios_base::out
to your arguments




#5070507 Syntax error which isn't an error? (Confused)

Posted by Joshhua5 on 17 June 2013 - 12:32 PM

Yeah, I've completely stripped all custom headers in the stdafx at first I though of making a Include.h for the includes, but that was just the same thing Obvious -facepalm-
So I've made sure all classes only call what they need and focused on reducing the reliance each class has on each other. practically to nill.

Moral of the story, be smart with your includes to avoid unneeded includes and loops. (It compiles :D)




#5068688 Models are missing half their triangles.

Posted by Joshhua5 on 10 June 2013 - 10:08 AM

For anyone who's interest, this is the progress made so far with the loader.

https://github.com/Joshhua5/DirectXEducationalProjects/tree/master/Lighting%20-%20Material%20Loader




#5067533 Camera Movement Math problem

Posted by Joshhua5 on 04 June 2013 - 11:14 PM

So strafing left would be position +-= right vector and

forwards would be position += look direction?

 

Thank you for your help Paradigm

 

EDIT: My problems have been solved and I have an idea on the view matrix now :D
though how it multiplies with other matrix's to create transformations is still over my head.




#5067275 Models are missing half their triangles.

Posted by Joshhua5 on 03 June 2013 - 11:46 PM

I've tried them all. List, Strip and Fan




#5067269 Models are missing half their triangles.

Posted by Joshhua5 on 03 June 2013 - 11:20 PM

https://docs.google.com/file/d/0B20ZnQ-9hBC3bHpacGl5ZGNOMG8/edit?usp=sharing

 

Lovely screenshot




#5067266 Models are missing half their triangles.

Posted by Joshhua5 on 03 June 2013 - 11:11 PM

I created a .OBJ loader and it loads correctly, I've matched the vertices to the ones in the file.

I load the vertices into a vertex buffer and draw it to the screen.

I export my model with Auto desk 3DSMAX 2013 and I have triangulated them.

I've been playing with this for a while now, but nothing seems to bring back my triangles :(

 

 

My source code is here:

https://docs.google.com/document/d/13bAxQgHXOjM0GtPLUt_As4EASpgr9FJ0EX7EgsFhzYI/edit?usp=sharing

My .Obj is here:

https://docs.google.com/document/d/1KToZx-iYCUVMzMeiLfuDP5bQc7M-CTo1fhC-SvtM9IY/edit?usp=sharing




PARTNERS