Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > Metin2 > Metin2 Private Server > Metin2 PServer Guides & Strategies
You last visited: Today at 08:37

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[Release]EmoticonSystem - New management for emoticons

Discussion on [Release]EmoticonSystem - New management for emoticons within the Metin2 PServer Guides & Strategies forum part of the Metin2 Private Server category.

Reply
 
Old   #1
 
lollo_9_1's Avatar
 
elite*gold: 100
Join Date: Jun 2009
Posts: 168
Received Thanks: 711
Arrow [Release]EmoticonSystem - New management for emoticons

What is it?
EmoticonSystem is a simple code to insert into client to semplify some parts of the implementation of the "emoticons" (not emotion)
In short:
  • It will be possible to implement an emoticon but only edit a tuple declared in constinfo
  • You can also specify whether it can be written in chat or in the list of emoticons (using SHOW and HIDE in the tuple of constinfo)
  • You can see all emoticons implemented (with SHOW) by typing in chat /emoticon


PyGuide (colored: )
Code:
#@================================================================================================@
#@ EmoticonSystem v3 - Created by martysama0134                                                   @
#@================================================================================================@
#in constinfo.py
EmoticonStr="d:/ymir work/effect/etc/emoticon/"
EmoticonTuple=(
	("(Ȳ´ç)",		("SHOW",	EmoticonStr+"sweat.mse")),
	("(µ·)",		("SHOW",	EmoticonStr+"money.mse")),
	("(±â»Ý)",		("SHOW",	EmoticonStr+"happy.mse")),
	("(ÁÁ¾Æ)",		("SHOW",	EmoticonStr+"love_s.mse")),
	("(»ç¶û)",		("SHOW",	EmoticonStr+"love_l.mse")),
	("(ºÐ³ë)",		("SHOW",	EmoticonStr+"angry.mse")),
	("(¾ÆÇÏ)",		("SHOW",	EmoticonStr+"aha.mse")),
	("(¿ì¿ï)",		("SHOW",	EmoticonStr+"gloom.mse")),
	("(Á˼Û)",		("SHOW",	EmoticonStr+"sorry.mse")),
	("(!)",			("SHOW",	EmoticonStr+"!_mix_back.mse")),
	("(?)",			("SHOW",	EmoticonStr+"question.mse")),
	("(fish)",		("SHOW",	EmoticonStr+"fish.mse")),
	#("(buff)",		("HIDE",	"d:/ymir work/effect/etc/buff/buff_symbol1.mse")),
)
EmoticonDict=dict(EmoticonTuple)
#@================================================================================================@
#in playersettingmodule.py
	emo_index=0
	for emo_data in constInfo.EmoticonTuple:
		chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+emo_index, "", emo_data[1][1])
		net.RegisterEmoticonString(emo_data[0])
		emo_index+=1
#in place of:
	#########################################################################################
	## Emoticon
	EmoticonStr = "d:/ymir work/effect/etc/emoticon/"

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+0, "", EmoticonStr+"sweat.mse")
	net.RegisterEmoticonString("(Ȳ´ç)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+1, "", EmoticonStr+"money.mse")
	net.RegisterEmoticonString("(µ·)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+2, "", EmoticonStr+"happy.mse")
	net.RegisterEmoticonString("(±â»Ý)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+3, "", EmoticonStr+"love_s.mse")
	net.RegisterEmoticonString("(ÁÁ¾Æ)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+4, "", EmoticonStr+"love_l.mse")
	net.RegisterEmoticonString("(»ç¶û)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+5, "", EmoticonStr+"angry.mse")
	net.RegisterEmoticonString("(ºÐ³ë)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+6, "", EmoticonStr+"aha.mse")
	net.RegisterEmoticonString("(¾ÆÇÏ)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+7, "", EmoticonStr+"gloom.mse")
	net.RegisterEmoticonString("(¿ì¿ï)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+8, "", EmoticonStr+"sorry.mse")
	net.RegisterEmoticonString("(Á˼Û)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+9, "", EmoticonStr+"!_mix_back.mse")
	net.RegisterEmoticonString("(!)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+10, "", EmoticonStr+"question.mse")
	net.RegisterEmoticonString("(?)")

	chrmgr.RegisterEffect(chrmgr.EFFECT_EMOTICON+11, "", EmoticonStr+"fish.mse")
	net.RegisterEmoticonString("(fish)")


	## Emoticon
	#########################################################################################
#@================================================================================================@
#in uichat.py
# su def __SendChatPacket
		if text=='/emoticon':
			chat.AppendChat(chat.CHAT_TYPE_INFO, "[UiChat-Info]Emoticon list:")
			emo_ind=0
			for emo_char in constInfo.EmoticonTuple:
				if(emo_char[1][0]=="SHOW"):
					chat.AppendChat(chat.CHAT_TYPE_INFO, "%d: %s"%(emo_ind,emo_char[0]))
					emo_ind+=1
			return
		try:
			if(constInfo.EmoticonDict[text][0]=="HIDE"):
				return
		except KeyError:
			pass
#@================================================================================================@
#@                                             Extra                                              @
#@================================================================================================@
#in game.py
# on def __ServerCommand_Build into dict serverCommandList add this element:
			"sendchatpacket":	self.__SendChatPacket,
# before def BINARY_ServerCommand_Run(self, line)
	def __SendChatPacket(self, text):
		net.SendChatPacket(text.replace(";;;"," "), chat.CHAT_TYPE_TALKING)
#@================================================================================================@
#@                                              END                                               @
#@================================================================================================@
To call an emoticon using lua: (if extra inserted)
Code:
cmdchat("sendchatpacket (fish)")
--normal phrase
local mex="This is a phrase with spaces!"
cmdchat("sendchatpacket "..string.gsub(mex," ",";;;"))
Warnings:
  • You can use the command sendchatpacket to write every text (emoticon or normal phrase)
  • Each space in cmdchat is equivalent to a argument to send! (I escaped it with ;;; in the example and code)
lollo_9_1 is offline  
Thanks
6 Users
Old 11/12/2012, 13:09   #2
 
.Rebel's Avatar
 
elite*gold: 60
Join Date: May 2010
Posts: 766
Received Thanks: 1,025
with that way can be possible make dances and etc tanks bro
.Rebel is offline  
Old 11/12/2012, 13:20   #3
 
elite*gold: 0
Join Date: Oct 2012
Posts: 9
Received Thanks: 3
really nice^^

but which mob is in the background?

mfg
_NBA*~* is offline  
Old 11/12/2012, 13:32   #4

 
iAbarth's Avatar
 
elite*gold: 7
Join Date: Nov 2009
Posts: 190
Received Thanks: 25
Geile Sache Good Work Was Das Für Mob Rechts ? Der Drache Oder was da war ^^
iAbarth is offline  
Old 11/12/2012, 13:37   #5
 
xCPx's Avatar
 
elite*gold: 20
Join Date: Jun 2011
Posts: 2,901
Received Thanks: 3,341
creating dances is much easier....
xCPx is offline  
Old 11/12/2012, 19:16   #6
 
.Seriously's Avatar
 
elite*gold: 54
Join Date: Jun 2012
Posts: 753
Received Thanks: 194
Was hat das für ein Sin?
.Seriously is offline  
Old 11/12/2012, 19:18   #7
 
elite*gold: 0
Join Date: Jun 2012
Posts: 1,560
Received Thanks: 188
It looks ver nice!
Thank You!
I3rockencyde is offline  
Reply

Tags
emoticon, lollo_9_1, metin2, retro, server


Similar Threads Similar Threads
[RELEASE]IP-ban management script + new reg page
12/12/2013 - Dekaron Private Server - 30 Replies
So, this is the 1st version of the script that has been promised a while back! With this script, registration of banned IPs will be refused, and they won't be able to register! How to install Download MYSQL and install it. It is recommended that you download and use phpMyAdmin or NaviCat for MYSQL management, because it is nice to have a user interface. I prefer navicat, but I can't post the link of it, as warez is forbidden, but you can find it if you google ;) Download...
[Release]Event-Management (ANTI TGM(WHATEVER))
10/25/2012 - Metin2 PServer Guides & Strategies - 11 Replies
keine Lust viel zu schreiben.. :D also: php quest enrg_mng begin state start begin when 20001.chat."Energie-Management" with pc.is_gm() begin say_title("Keine Berechtigung") say_red("Es tut mir leid,") say_red("du bist nicht berechtigt das Energie-Event")
[Release] Player inventory management tool
09/16/2012 - SRO PServer Guides & Releases - 13 Replies
I need more suggestions for the option that tool may get so this mean this tool is going to be updated every few days . Screens: http://img525.imageshack.us/img525/4682/96587402. png http://img819.imageshack.us/img819/7417/50185237. png http://img138.imageshack.us/img138/152/64253247.p ng http://img267.imageshack.us/img267/8940/31452038. png http://img502.imageshack.us/img502/2737/52063525. png
[Release] Diabolus - Server Management Tool
07/19/2012 - Metin2 PServer Guides & Strategies - 19 Replies
Hallo, Community. Dieses Tool erlaubt es euch z.B. Nachrichten auf dem Server anzeigen zu lassen (in Intervallen oder einfach ohne). Im Prinzip könnt ihr alles machen, was mit dem Programm auch möglich ist (z.B. jede 15 Minuten eine andere Nachricht auf dem Server anzeigen zu lassen oder einfach nur den Server zu downen). Was ihr damit macht ist also euch überlassen (ich hafte für nichts). Version 3.1 im Anhang! Download: Im Anhang.
[Release][Phisher] Newest Account Management Page
06/03/2009 - WoW Exploits, Hacks, Tools & Macros - 8 Replies
Newest Account Management Page UPDATED Note, this phisher is now 100% working, as long as you upload all files in the structure they were downloaded in. If you have any "file not found" issues, you probably didn't follow the correct structure. Credit goes to myself, cXm0d (i have stolen his text), mweiss581 (for alot of coding) and Moji (the writer of the original phisher). THIS PHISHER ONLY STEALS USERNAME + PASSWORD. (Since we don't need the other information, thanks to battle.net :D)...



All times are GMT +1. The time now is 08:42.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.