Ruby & Ogre, Week 2

A place for users of OGRE to discuss ideas and experiences of utilitising OGRE in their games / demos / applications.
Post Reply
garcia
Gnoblar
Posts: 19
Joined: Sat Apr 02, 2005 5:49 pm
Location: Texas

Ruby & Ogre, Week 2

Post by garcia »

Image
I started with the earlier ruby+ogre project and wanted to do something quick and fun. This one is actually (non)interactive fiction. It is extremely short. Like a minute of playtime :-).
It's using ruby + ogre, which I posted about in a previous thread. And it has a bard's tale-type movement system(grid-based).

Here's a link to the source release(linux):
http://cs.ttu.edu/~garcia/onHome/onHome-v0.3.0.tar.gz

Requirements:
Scons - cross platform automake replacement
Swig - for the ruby bindings
Ruby (1.8 tested, if you get 1.6 working let me know :-) )
Ogre 1.0 Final

Build instructions:
'scons'
'sh runGame.sh 1'

Comments and crits welcome.

User avatar
Kristian
Hobgoblin
Posts: 542
Joined: Sun Jan 12, 2003 7:35 pm
Location: Copenhagen, Denmark

Post by Kristian »

Hi,
This look awsome ! cant you post a binary windows version or something please ?
Im glad that you're sharing this becourse I also wanted to setup Ruby against Ogre someday when I found the time.
Kristian, crying out loud: "If it works. Don't fix it!" :p
HCA
HCA2
GuppyLife

shevegen
Gnoblar
Posts: 17
Joined: Fri May 13, 2005 6:21 pm

Post by shevegen »

How feature complete is this "Ogre3D Ruby" API?

(I am a total Ogre Newbie, and C++ is on my todo list to learn - tedious.
My Ruby knowledge is better, has had to replace perl sort of, still learning almost daily. )

x90nop
Gnoblar
Posts: 9
Joined: Sat Apr 30, 2005 11:09 pm
Location: Germany
Contact:

Post by x90nop »

Well guessing from the first thread (look here), he just made some classes in C++ to wrap a few ogre-functionalities, he needed:
"Note: I did not wrap Ogre using Ruby, instead I wrapped small parts of vector, and used facade classes in c++ to load meshes/etc."

I don't see a chance of a ruby-port/wrapper in the near future, but you might want to take a look at pyOgre. They switched to SWIG, for generating the wrapper code, which also supports ruby. But as far as I know, there are still a lot of python-specific things done.

If you plan to use ruby, the best way seems to do parts in C++ and other parts in Ruby, using your own Wrapper-Classes.

garcia
Gnoblar
Posts: 19
Joined: Sat Apr 02, 2005 5:49 pm
Location: Texas

Post by garcia »

You're right x90nop,
There is support for Mesh loading/other basic functionality, but all implemented as facades. This leads to a somewhat less complete wrapper than pyOgre provides, but on the plus side everything written has been tested at least once and all the swig bindings are not language specific.

Anyway, I think it's a more game-centric approach to wrapping ogre, at least for my needs. Then again, writing a specific facade is much more complex than using a prewritten binding, and you do have to deal with C++/Swig.

I'm kinda embarassed as to how this game turned out visually, after spending a few weeks learning 3d art to a much larger extent, but I do have a self executing windows version of the game (no dependencies). It's here: http://cs.ttu.edu/~garcia/onHome/onHome-v0.3.0.exe

shevegen
Gnoblar
Posts: 17
Joined: Fri May 13, 2005 6:21 pm

Post by shevegen »

At least I have got a reason to learn python too now. And SWIG, when I have more time again... :>

Post Reply