Advertisement Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Something that could be done better

Sign in to follow this  


This is how OIS code actually looks:

OIS::Keyboard* keyboard = static_cast(inputSystem->createInputObject(OIS::OISKeyboard, false));


OIS::Keyboard* keyboard = OIS::Keyboard::Create(inputSystem, false);

No typecodes. No casting.
Sign in to follow this  


Recommended Comments

Because there is no OIS::Keyboard::Create function in OIS. Their design requires that you use the first snippet.

I guess I could submit a patch or something.

Share this comment

Link to comment
You can partially blame me for having to do that :) I made the exact same change you did but I didn't submit a patch for it.

Share this comment

Link to comment

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

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!