Jump to content

Recommended Posts

Toda vez que ativo o macro que implementei no jogo me da esse erro, alguém sabe o motivo?

 

1009 21:24:07088 ::   File "game.py", line 1338, in OnKeyUp

1009 21:24:07088 :: TypeError
1009 21:24:07088 :: : 
1009 21:24:07088 :: 'NoneType' object has no attribute '__getitem__'
1009 21:24:07088 :: 

Link to post
Share on other sites
Guest Ezrekith

Hi.

Replace the whole function with this:
 

	def OnKeyUp(self, key):
		try:
			self.onClickKeyDict[key]()
		except KeyError:
			pass
		except:
			raise

		return True

There are some clients which use the old key function and yea thats kinda outdated i guess..

And check if you have this line:

self.onClickKeyDict = None

In your game.py in the Close definition (def Close(self):)

 

If this does not fix your problem, please tell me when do you get this log so i can think about other stuffs, thanks! :)

Edited by Ezrekith
Im dumb lol..
Link to post
Share on other sites

Mine is that way and still keeps making mistakes.

 

def OnKeyUp(self, key):
        try:
            self.onClickKeyDict[key]()
        except KeyError:
            pass
        except:
            raise

        return TRUE

Link to post
Share on other sites
16 horas atrás, Shabba disse:

Hi.

Replace the whole function with this:
 

Hidden Content

    Give reaction or reply to this topic to see the hidden content.

There are some clients which use the old key function and yea thats kinda outdated i guess..

And check if you have this line:

Hidden Content

    Give reaction or reply to this topic to see the hidden content.

In your game.py in the Close definition (def Close(self):)

 

If this does not fix your problem, please tell me when do you get this log so i can think about other stuffs, thanks! :)

Vi um rapaz com o mesmo problema, no servidor principal(no dedicado) ao abrir o armazém/item mall e sair correndo sem clicar no X, o cliente fecha e dá esse erro, já no servidor de testes (.vdi) não apresenta esse problema mas ambos possuem os mesmos arquivos files/cliente.

Link to post
Share on other sites
  • 2 years later...
  • 8 months later...
  • 2 weeks later...
  • 2 months later...
  • 4 weeks later...
  • 3 weeks later...
  • 4 weeks later...
  • 3 weeks later...
  • 1 month later...
On 10/15/2017 at 12:46 AM, Guest Ezrekith said:

Hi.

Replace the whole function with this:
 

Hidden Content

  • Give reaction or reply to this topic to see the hidden content.

There are some clients which use the old key function and yea thats kinda outdated i guess..

And check if you have this line:

Hidden Content

  • Give reaction or reply to this topic to see the hidden content.

In your game.py in the Close definition (def Close(self):)

 

If this does not fix your problem, please tell me when do you get this log so i can think about other stuffs, thanks! :)

 

Link to post
Share on other sites

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
×
×
  • Create New...