Jump to content

Recommended Posts

Hy!

bye would be a problem to have a rotation feature that is key, and is connected to the rotating characters,

The function here

 

    def __OnClickPrevRotate(self):
        self.Rotation = self.Rotation - 1
        chr.SetRotation(self.Rotation)

 


My question to be solved long as you hold the button to the characters constantly spinning when you release the button used to rotation

Thank you in advance for your answers

Link to comment
https://metin2.dev/topic/11693-python-rotation-funkcio-help/
Share on other sites

Try this:

self.isActiveRotation = False
self.button.SetMouseClickEvent(self.ActiveRotation)
self.button.SetMouseButtonUpEvent(self.DeactiveRotation)

def ActiveRotation(self):
    self.isActiveRotation = True
    
def DeactiveRotation(self):
    self.isActiveRotation = False
    
def OnUpdate(self):
    if self.isActiveRotation:
        self.Rotation -= 1
        chr.SetRotation(self.Rotation)

  • Love 1
  • 2 weeks later...

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.