I'm a really noob in this.. need a hand :P

digimikeh

19-02-2009 01:20:15

Hello....

I'm learning python at the same time Python-ogre. I downloaded the following four files.. :

------

OgreSDKSetup1.6.1_CBMingW

Python-Ogre-1.6.1-r845-py252

BlenderExport

demo_media_1.2.0

------

I tried to do the beginner tutorials the first one, "basic_01.py", I noticed that tutorial is based in version 1.0 so, then investigated that the first line must be changed... precisely " import pyogre " to " import ogre.renderer.OGRE as ogre "

import ogre.renderer.OGRE as ogre
import SampleFramework as sf


class TutorialApplication():

def _createScene(self):
pass

if __name__ == "__main__":
ta = TutorialApplication()
ta.go()


Typed all the same, like is written in tutorial.. but i got this error in shell:

Traceback (most recent call last):
File "C:\Documents and Settings\Administrador\Escritorio\PyogreTutorial\Mine\basic_01.py", line 12, in <module>
ta.go()
AttributeError: TutorialApplication instance has no attribute 'go'


I appreciate any help....

Thanks..

jsgreenawalt

19-02-2009 03:35:48

Hey digimikeh, looks like you missed something on this line:

class TutorialApplication():

should be:

class TutorialApplication(sf.Application):

The go method is inherited from the sf.Application class, so without specifying that class as the parent class of TutorialApplication, your class doesn't have a go method. Hope that helps.

- Joe G

digimikeh

19-02-2009 14:16:28

Thanks Joe, i saw that the error was i missed that line you just signaled, I added that.. but the problem persist.... i don't know why,... .. if modules import correctly... seems to be that before that script i must to insert others line.... did you try that tutorial?, can you tell me where to find more tutorials?..

Thanks again !..

digimikeh

19-02-2009 14:20:21

I got what was the problem!!,,, I missed a "p" in application name just typed aplication... ^__