Jump to content

Recommended Posts

Hello guys,

I tried to add time and lv in PM and my client started to crash on login.

That's the code:

Quote

def SendWhisper(self):
      import time
      import player
      text = self.chatLine.GetText()
      textLength = len(text)
      if textLength > 0:
         if net.IsInsultIn(text):
            chat.AppendChat(chat.CHAT_TYPE_INFO, locale.CHAT_INSULT_STRING)
            return
         VectorsOra = time.strftime("%H:%M:%S")
         net.SendWhisperPacket(self.targetName, "[Ora" + VectorsOra + "[Lv" + str(player.GetStatus(player.LEVEL)) + "]: " + text)
         self.chatLine.SetText("")
         chat.AppendWhisper(chat.WHISPER_TYPE_CHAT, self.targetName, player.GetName() + "[Ora" + VectorsOra + "[Lv" + str(player.GetStatus(player.LEVEL)) + "]: " + text)

I added

Quote

import chr
import time
import os

at the beggining of the uiwhisper.py too.

 

The syserr have the next error:

Quote

networkModule.py(line:194) SetSelectCharacterPhase
system.py(line:130) __pack_import
system.py(line:110) _process_result
introSelect.py(line:12) ?
system.py(line:130) __pack_import
system.py(line:110) _process_result
introSelect_new.py(line:27) ?
system.py(line:130) __pack_import
system.py(line:110) _process_result
interfaceModule.py(line:20) ?
system.py(line:130) __pack_import

networkModule.SetSelectCharacterPhase - exceptions.IndentationError:expected an indented block (line 248)

0505 03:40:06023 :: ============================================================================================================
0505 03:40:06023 :: Abort!!!!

I tried to use TABs etc and nothing helped. A little help would be awesome. Thanks a lot.

I solved it adding one more TAB to the imports from def to be inside of it.

https://metin2.download/picture/KQBe96PwR37X8lBDQ561umJ1FdLp4aF8/.png

Edited by Metin2 Dev
Core X - External 2 Internal
Link to comment
Share on other sites

  • Premium

There's not much to say, it's an indentation problem. You gotta find all the spaces and substitute them with a tab. Or you are missing one tab in the line 248.

  • Love 1

 

"Nothing's free in this life.

Ignorant people have an obligation to make up for their ignorance by paying those who help them.

Either you got the brains or cash, if you lack both you're useless."

Syreldar

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



  • Similar Content

  • Activity

    1. 60

      Inbuild GR2 Animation

    2. 2

      wait() function bug

    3. 0

      Remove Party Role Bonuses

    4. 1

      Fix CBar3D

    5. 2

      set_quest_state not working

    6. 1

      Fix CBar3D

  • Recently Browsing

    • No registered users viewing this page.
×
×
  • 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.