Programming RPG with DirectX ( DX 9 code )

Started by
25 comments, last by SirPaladin 20 years, 10 months ago
[GI]-Matt,
trust me,
I HAVE BOUGHT mr adams rpg book,i could always take a webcam shot of me holding it in my hands J
Matt_Smith.
Advertisement
quote:Original post by yzzid
When I was going through all the source and updating it, it appears that the debug version is the only one set up for each project. So what I did was go through and make all the changes so the release build can be made also. When I did this I noticed that there is a problem in the input system. Not sure what it is but in the MeshLvl sample if you build the release version and move the mouse the key states all get set. Not sure why this is happening as they are two separate objects.

There is definitely some wierd optimization thing going on here. When I checked the value of BufferSize in the InputDevice::Read function they were all 0!! Must be something to do with the optimizer. When I made the variable static the values were OK. Has anyone else seen this behavior?

-dizzy
Game Institute Intern


[edited by - yzzid on June 17, 2003 11:32:09 AM]



The last time I had problems with Input in Jim''s engine
was because of the char type for all his input variables.
Changing them to unsigned char solved the problem but I am
not sure if this is your problem as well.


_________________
Best regards,
Sherman Chin
www.Sherman3D.com
_________________ Best regards, Sherman Chin Director Sherman3D (Malaysia) Sdn Bhd www.Sherman3D.com www.AlphaKimori.com
chars and unsigned chars are the same size in memory. I don''t think that is what is causing the problem but you never know with Microsoft''s compiler. Not sure why a local variable isn''t get set correctly in release but is in debug. I have never seen that happen before!

-dizzy
Game Institute Intern
-dizzyGame Institute InternPlease rate me. :)
Sherman,

Sorry. You were right. I didn''t understand what you were saying.

The input parameters to the GetKeyState and GetPureKeyState should be unsigned chars instead of plain chars. I noticed when I ran through te debugger that they were getting negative values. Not good. I''m not sure why the debug version works and the release version doesn''t though. I guess Jim only built the debug versions for the book.

-dizzy
Game Institute Intern
-dizzyGame Institute InternPlease rate me. :)
I never did that at least. Darn.
quote:Original post by yzzid
Sherman,

Sorry. You were right. I didn't understand what you were saying.

The input parameters to the GetKeyState and GetPureKeyState should be unsigned chars instead of plain chars. I noticed when I ran through te debugger that they were getting negative values. Not good. I'm not sure why the debug version works and the release version doesn't though. I guess Jim only built the debug versions for the book.

-dizzy
Game Institute Intern


No problem. ^_^ Sorry for not explaining better - it has been a while since I solved
that and I thought it might be the cause of this problem because I asked in this forum
before and nobody could give me an answer - I had to figure it out
myself eventually. I hope my experience helps everyone else with the same problem.
Jim, perhaps you should put up a message about this on your website? ^_^ It was
really irritating trying to figure out why the engine worked in debug mode and not in release mode. >_<
Thanks ^_^


_________________
Best regards,
Sherman Chin
www.Sherman3D.com

[edited by - sherman on June 20, 2003 1:33:06 AM]
_________________ Best regards, Sherman Chin Director Sherman3D (Malaysia) Sdn Bhd www.Sherman3D.com www.AlphaKimori.com
I am also having problems with the 2Din3D program in release mode. The background isn''t showing up. I assume there may be another problem in the graphics core. Perhaps when I have some time I will try to figure it out.

-dizzy
Game Institute Intern
-dizzyGame Institute InternPlease rate me. :)

This topic is closed to new replies.

Advertisement