Jump to content

Recommended Posts

  • Honorable Member

M2 Download Center

This is the hidden content, please
( Internal )

This is the hidden content, please
( GitHub )

Spoiler

28063568747470733a2f2f6d656469612e676970

 

  • Metin2 Dev 136
  • kekw 1
  • Eyes 3
  • Dislove 3
  • Not Good 2
  • Think 1
  • Confused 2
  • Good 28
  • Love 4
  • Love 82

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/
Share on other sites

Hi there, first, thanks for you sharing, 


But there is a problem for users of 2008 c++ compilator:

 std::vector::emplace_back

Used in PythonWhisper.h: {if (std::find(b_writing[i].begin(), b_writing[i].end(), name) == b_writing[i].end()) b_writing[i].emplace_back(name);};

 

Isn't supported (https://en.cppreference.com/w/cpp/container/vector/emplace_back) due to older c++ version.

 

Anyway, thanks for the share :)

 

  • Good 1
 

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-113016
Share on other sites

I don't use vs2008 xD

 I just tell it because many people will come there and cry because they've followed tutorials ?

 

Anyway your system works but there's 2 problems I let you show 

https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif (1 can be fixed easly on the source)

https://metin2.download/picture/r3F9504x09DVmF8K988YXgTtGTP6KMUj/.gif

(Without submitting anything)

 

 

Edited by Metin2 Dev
Core X - External 2 Internal
  • Dislove 1
  • Think 1
 

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-113021
Share on other sites

Take a look:

image.png.3cf26ccede5defa7ae6a15283643d2a6.png

 

An example: Hi {enter} Hi {delete} Salut {enter} there is already 8 request (also 8 logs) for 2 words.

ERm2Abu.png

 

I think with many players it can be a real problems of performance and mysql spam.

Edited by Metin2 Dev
Core X - External 2 Internal
 

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-113025
Share on other sites

  • Honorable Member
10 minutes ago, tmoitoi said:

Take a look:

image.png.3cf26ccede5defa7ae6a15283643d2a6.png

 

An example: Hi {enter} Hi {delete} Salut {enter} there is already 8 request (also 8 logs) for 2 words.

ERm2Abu.png

 

I think with many players it can be a real problems of performance and mysql spam.

I changed code in PythonNetworkStreamPhaseGame.cpp. Can you test it? Thanks for the message :)

6 minutes ago, hachiwari said:

Nice piece of shit

bone-157272_1280.png

Edited by Metin2 Dev
Core X - External 2 Internal
  • Love 3

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-113027
Share on other sites

  • Active+ Member
59 minutes ago, tmoitoi said:

Still the same

You can try to add a bypass for log this with regex 

Here is a example 

http://txt2re.com/index-c++.php3?s=|?whisper_renewal<|&3&-1

 
	// URL that generated this code:
	// http://txt2re.com/index-c++.php3?s=|?whisper_renewal<|&3&-1
	 
	#include <stdlib.h>
	#include <string>
	#include <iostream>
	#include <pme.h>
	 
	int main()
	{
	  std::string txt="|?whisper_renewal<|";
	 
	  std::string re1=".*?"; // Non-greedy match on filler
	  std::string re2="(whisper_renewal)"; // Variable Name 1
	 
	  PME re(re1+re2,"gims");
	  int n;
	  if ((n=re.match(txt))>0)
	  {
	      std::string var1=re[1].c_str();
	      std::cout << "("<<var1<<")"<< std::endl;
	  }
	}
	 
	//-----
	// C++ does not provide a regular expression feature as standard.
	//
	// To run this code you will need to first download and install
	// the PCRE library from http://www.pcre.org/ and 
	// the PME library from ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/Contrib/
	// 
	// Note that on Linux systems PCRE is often already installed in /usr/lib/libpcre* or /usr/local/lib/libpcre*. 
	//
	// Compile and run on Unix using 
	// # c++ x.cpp -lpme -lpcre 
	// # ./a.out
	

 

 

With c++11 is easy with std::regex

 

  • Metin2 Dev 1
  • Love 1
Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-113032
Share on other sites

  • 4 weeks later...

I have problem in clinet, 

 

0412 16:45:37904 ::   File "uiWhisper.py", line 303, in OnUpdate

0412 16:45:37906 :: AttributeError
0412 16:45:37906 :: : 
0412 16:45:37907 :: 'NoneType' object has no attribute 'GetText'
0412 16:45:37908 :: 
 

Spoiler

                if len(self.chatLine.GetText()) > 0 and not whisper.IsSended(self.targetName):

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114115
Share on other sites

Dnia 12.04.2019 o 16:56, kondzio299 napisał:

I have problem in clinet, 

 

0412 16:45:37904 ::   File "uiWhisper.py", line 303, in OnUpdate

0412 16:45:37906 :: AttributeError
0412 16:45:37906 :: : 
0412 16:45:37907 :: 'NoneType' object has no attribute 'GetText'
0412 16:45:37908 :: 
 

  Odkryj ukrytą treść

                if len(self.chatLine.GetText()) > 0 and not whisper.IsSended(self.targetName):

 

can anyone help? Please

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114251
Share on other sites

  • Forum Moderator
On 4/12/2019 at 5:56 PM, kondzio299 said:

0412 16:45:37904 ::   File "uiWhisper.py", line 303, in OnUpdate

0412 16:45:37906 :: AttributeError
0412 16:45:37906 :: : 
0412 16:45:37907 :: 'NoneType' object has no attribute 'GetText'
0412 16:45:37908 :: 

You should replace the condition in function OnUpdate:

#if 0 != self.targetName:
if self.targetName and self.chatLine:

 

  • Love 1
Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114252
Share on other sites

  • Honorable Member
54 minutes ago, VegaS™ said:

You should replace the condition in function OnUpdate:


#if 0 != self.targetName:
if self.targetName and self.chatLine:

 

Updated thanks :)

  • Love 1

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114257
Share on other sites

Révélation

 

0417 04:02:51745 ::   File "ui.py", line 1020, in CallEvent

0417 04:02:51745 ::   File "ui.py", line 88, in __call__

0417 04:02:51745 ::   File "ui.py", line 70, in __call__

0417 04:02:51745 ::   File "uiWhisper.py", line 316, in AcceptTarget

0417 04:02:51746 ::   File "interfaceModule.py", line 1488, in RegisterTemporaryWhisperDialog

0417 04:02:51746 ::   File "uiWhisper.py", line 224, in OpenWithTarget

0417 04:02:51746 ::   File "uiWhisper.py", line 322, in SetTimer

0417 04:02:51746 :: NameError
0417 04:02:51746 :: : 
0417 04:02:51746 :: global name 'time' is not defined

 

*edit *solved

 
Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114314
Share on other sites

Acum 13 minute, Raptt a spus:


0417 04:02:51745 ::   File "ui.py", line 1020, in CallEvent

0417 04:02:51745 ::   File "ui.py", line 88, in __call__

0417 04:02:51745 ::   File "ui.py", line 70, in __call__

0417 04:02:51745 ::   File "uiWhisper.py", line 316, in AcceptTarget

0417 04:02:51746 ::   File "interfaceModule.py", line 1488, in RegisterTemporaryWhisperDialog

0417 04:02:51746 ::   File "uiWhisper.py", line 224, in OpenWithTarget

0417 04:02:51746 ::   File "uiWhisper.py", line 322, in SetTimer

0417 04:02:51746 :: NameError
0417 04:02:51746 :: : 
0417 04:02:51746 :: global name 'time' is not defined

import time

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-114315
Share on other sites

  • 4 weeks later...
  • 4 weeks later...
Le 14/05/2019 à 07:18, cjunior2011 a dit :

what's wrong?
 

  Révéler le contenu masqué

ihrR4z8.gif

code:

  Révéler le contenu masqué

19wcUWJ.png

 

Try :
 

def Close(self):
        chat.ClearWhisper(self.targetName)

        if app.ENABLE_WHISPER_RENEWAL:
            if self.targetName != 0:
                if whisper.IsSended(self.targetName) and self.targetName:
                    whisper.Remove(self.targetName)

Edited by Metin2 Dev
Core X - External 2 Internal
  • Love 1
Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-115778
Share on other sites

21 hours ago, IShungite said:

Try :
 

def Close(self):
        chat.ClearWhisper(self.targetName)

        if app.ENABLE_WHISPER_RENEWAL:
            if self.targetName != 0:
                if whisper.IsSended(self.targetName) and self.targetName:
                    whisper.Remove(self.targetName)

#Solved
thank u very much, its solved my problem, @IShungite

  • Love 1

tenor.gif

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-115799
Share on other sites

  • 1 month later...

I followed the Tutorial but when i click on the Whisper Button my Metin2 crashed.

 

Hope anyone can help me.

uiWhisper.py(line:94) LoadDialog
ui.py(line:2832) GetChild

DialogWindow.LoadDialog.BindObject - <type 'exceptions.KeyError'>:'typing'

0723 10:16:40437 :: ============================================================================================================
0723 10:16:40437 :: Abort!!!!

 

uiwhisper.py

		try:
			GetObject=self.GetChild
			self.titleName = GetObject("titlename")
			self.titleNameEdit = GetObject("titlename_edit")
			self.closeButton = GetObject("closebutton")
			self.scrollBar = GetObject("scrollbar")
			self.chatLine = GetObject("chatline")
			self.minimizeButton = GetObject("minimizebutton")
			self.ignoreButton = GetObject("ignorebutton")
			self.reportViolentWhisperButton = GetObject("reportviolentwhisperbutton")
			self.acceptButton = GetObject("acceptbutton")
			self.sendButton = GetObject("sendbutton")
			self.board = GetObject("board")
			self.editBar = GetObject("editbar")
			self.gamemasterMark = GetObject("gamemastermark")
			#typing
			if app.ENABLE_WHISPER_RENEWAL:
				self.typing = GetObject("typing")
		except:
			import exception
			exception.Abort("DialogWindow.LoadDialog.BindObject")

 

Link to comment
https://metin2.dev/topic/20842-typing-information-whisper/#findComment-117512
Share on other sites

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.