Met an error in renpy when writing the action function of an image button like below :
action Function( '\u2192', pygame.K_RIGHT)
Error shown as below :
File "renpy/common/00action_other.rpy", line 583, in __call__
rv = self.callable(*self.args, **self.kwargs)
TypeError: 'str' object is not callable
Forgot to add the function name
Corrected the syntax to below (also added the parameter name to before value):
action Function(simulate_keypress, unicode_key='\u2192', pygame_key=pygame.K_RIGHT)
No comments:
Post a Comment