0

I am constantly getting these errors such as: NameError: name 'mouse' is not defined or NameError: name 'screen' is not defined, etc.

Here is my full error message in the Python shell: 2.7.8 (v2.7.8:ee879c0ffa11, Jun 29 2014, 21:07:35) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] Python Type "help", "copyright", "credits" or "license" for more information. [evaluate ourGame.py] Traceback (most recent call last): File "/Volumes/PATRIOT/Our Game/ourGame.py", line 44, in <module> NameError: name 'mouse' is not defined

I have installed Python 2.7.8 32 bit, Pygame 32 bit, and the Livewires library.

I've imported the Livewires library with the line: from livewires.beginners import *

Here is where I am getting errors: mouse.is_visible = False

It might be due to the fact that I did not properly install Pygame or Livewires, but when I type in the following into the Python command window I don't get errors:

from livewires import beginners from livewires import games

  • We can haz more code? – David Frye Aug 02 '14 at 22:40
  • Are you sure `mouse` is defined in `beginners`? The [source](https://github.com/livewires/python/blob/master/module/livewires/beginners.py) suggests otherwise. – jonrsharpe Aug 02 '14 at 22:41
  • Do you import the [module from `pygame`](http://www.pygame.org/docs/ref/mouse.html)? – jonrsharpe Aug 02 '14 at 22:47
  • I took an intro class to python and the command they used was `from livewires.beginners import *`. I am having issues when I use `screen.event_grab` or `mouse.is_visible`. I believe I have installed pygame from their Downloads page, but I am unsure how I can make sure it has been installed correctly. I'll try importing the module. – user3902971 Aug 02 '14 at 23:27

0 Answers0