开发者

Common game controls/ User interface libraries or source code?

Sorry for the ackward title, but i don't know what to call it exactly. I'm looking for code or libraries that allow easy creation of co开发者_运维百科mmonly used user input devices, and code/libs that make gaming controls easy to set up (i'm using SFML and Box2D at the moment)

I don't want to re-invent things like buttons, arrows being placed wherever the mouse is located, and more game specific items such as "controls settings" or even being able to drag objects around with the mouse.

More specifically i want source code for interfaces that....

  • Makes Buttons and Textboxes easy to create
  • allows mouse input to press buttons or drag objects in games
  • has "Focuses" (like a textbox being able to gain focus and be typed in)
  • Is compatable with SFML/Box2D

and code for common game mechanics/controls that....

  • Allows easy setup of controls for a game
  • Makes events like clicking and holding on an object easy to setup, as so objects can be dragged around afterward

Are there any simple libraries or resources out there that i can use to avoid spending much of my time coding these now standard input devices/tecniques?


I think CEGUI is the type of thing you are looking for:

http://www.cegui.org.uk/wiki/index.php/Main_Page

It is a GUI framework to work with OpenGL. Some others can be found in this list.


Still, if I were you, I would just use a major toolkit, such as GTK, Qt, or wxWidgets combined with SFML instead of dealing with CEGUI.

SFML has guides for Qt and wxWidgets with the rest of them at http://www.sfml-dev.org/tutorials/1.6/.

I have created my own little guide for GTK here: http://lalaland.github.com/gtkGuide.html

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜