Jump to content

flygun

Former Staff
  • Posts

    729
  • Joined

  • Last visited

  • Days Won

    7
  • Feedback

    0%

Posts posted by flygun

  1. You know that the system as released here works perfectly or? 

     

    But you need correct entries in the serverinfo and also the right ports

     

    Also the map checks is serverside 

    If Ch99 isn't set to the map then you function allways returns if player is in ch99

    The clientside part I just took from wom2 because was too lazy go create own guy 

     

    i'm not saying that the system doesn't work i just can't open tow channels at the same time to test it (i don't know why -still investing.)... plus about the map check the server never check where is he going (to which map) just checks if the map index found or not ....

    to be more specific i'm talking about those maps

    		dis_maps = [
    			"season1/metin2_map_oxevent",
    			"season2/metin2_map_guild_inside01",
    			"season2/metin2_map_empirewar01",
    			"season2/metin2_map_empirewar02",
    			"season2/metin2_map_empirewar03",
    			"metin2_map_dragon_timeattack_01",
    			"metin2_map_dragon_timeattack_02",
    			"metin2_map_dragon_timeattack_03",
    			"metin2_map_skipia_dungeon_boss",
    			"metin2_map_skipia_dungeon_boss2",
    			"metin2_map_devilsCatacomb",
    			"metin2_map_deviltower1",
    			"metin2_map_t1",
    			"metin2_map_t2",
    			"metin2_map_t3",
    			"metin2_map_t4",
    			"metin2_map_t5",
    			"metin2_map_wedding_01",
    			"metin2_map_duel",
    			"metin2_map_orclabyrinth",
    			"metin2_map_n_flame_dungeon_01",
    			"metin2_map_n_snow_dungeon_01"
    		]

    you can open the index file from map folder in the server and take the indexes of these maps

    and check them in the c++ code ... (server side)

  2.  idk why he wrote the map check function with python he could do it with c++ :mellow:

     

    and i'm very sorry i don't know how to use spoiler with this new interface (design):blush:

    Just write [ spoiler ] [ /spoiler ] without spaces and...

     

    Hidden Content

    thank you ;) .... anyway i got some problems with my FreeBSD OS so i can't test the system with server so i just wrote the codes cus i just couldn't see the python code look like this without rewriting it lol

     

    btw with / without my code the /channel x problem is still there so i think he must write it with some c++ codes to be more functional

  3. I'm using vmWare and the system currently occupies about 10gb disk space out of 40gb maximum. So I'll only have to upload 10gb but unfortunetately my connection is so bad that I even can't seem to upload them. I only upload with 100kb/s, which equals to 10 hours upload time :/

     

    Edit: It's 100 hours, not 10. Sorry for the missing 0 :/

    you can use this for VMWare

    C:\Program Files\VMWare\VMWare Server> vmware-vdiskmanager.exe -k "D:\Virtual Machines\my_hd.vmdk"

    you can also use this command if you're using freebsd OS

    cat /dev/zero > zero.fill;sync;sleep 1;sync;rm -f zero.fill
    

     

    use the command then use the cmd command ... i saved 7GB :)

    • Love 1
  4. thx for the system i didnt test it or add it
    also iam not c++ progream but your code it seem to be ugly -_-

    good luck :)

    Really? I can't find anything ugly about this. Actually the c++ part is very nice. I didn't check on python.

    And why are you wishing him good luck at his own release? ._. Sometimes I don't understand people...^^

     

    Anyway, the idea behind that is great and I like the c++ part a lot. Oh, and a german sentence slipped through ;)

     

    I know that it isn't the best c++ Code, but I really.love using maps ^^

     

    Py part is 1:1 from wom:o

     

    And yeah the German sentence comes through :D

    sorry for that ^^

    Mobile phone and yeah :D

    i dont know how to tell u why he is ugly

    also iam arabic from libya not germany

    alina wasn't talking to  you when he/she wrote this ---> "and a german sentence slipped through ;)"

    he/she was talking to the topic maker

     

    and for the python part :

    go to uisystem.py in root and search for this tow times

    self.GetChild("help_button").SAFE_SetEvent(self.__ClickHelpButton)

    and under it write this

    self.GetChild("Change_Channel").SAFE_SetEvent(self.__ClickChangeChButton)

    and after this

    	def __ClickInGameShopButton(self):	   	
    	   	self.Close()
    		net.SendChatPacket("/in_game_mall")

    write this

     

    	def	__ClickChangeChButton(self):
    		if constInfo.channel == 0:
    			constInfo.channel == 1
    			self.uuchangechannel = uichannel.ChannelChanger()
    			self.uuchangechannel.Show()
    		elif constInfo.channel == 1:
    			constInfo.channel == 0
    			self.uuchangechannel = uichannel.ChannelChanger()
    			self.uuchangechannel.hide()

    save and exit

    2: change uichannel.py in root with this

    import ui
    import net
    import app
    import chat
    import math
    import wndMgr
    import serverInfo
    import background
    import ServerStateChecker
    import snd
    import constInfo
    Channel_window = "uiscript/channel.py"
    class ChannelChanger(ui.ScriptWindow):
    	def __init__(self):
    		ui.ScriptWindow.__init__(self)
    
    	def __del__(self):
    		ui.ScriptWindow.__del__(self)
    
    		
    	def Show(self):
    		self.__LoadWindow()
    		ui.ScriptWindow.Show(self)
    		
    	def __LoadWindow(self):
    		try:			
    			pyScrLoader = ui.PythonScriptLoader()
    			pyScrLoader.LoadScriptFile(self, Channel_window)
    		except:
    			import exception
    			exception.Abort("PetWindow.LoadWindow.LoadObject")
    		#buttons
    		self.TitleBar = self.GetChild("TitleBar")
    		self.channel1 = self.GetChild("Channel_1")
    		self.channel2 = self.GetChild("Channel_2")
    		self.channel3 = self.GetChild("Channel_3")
    		self.channel4 = self.GetChild("Channel_4")
    		
    		#event buttons
    		self.TitleBar.SetCloseEvent(ui.__mem_func__(self.Close))
    		self.channel1.SetEvent(ui.__mem_func__(self.___1))
    		self.channel2.SetEvent(ui.__mem_func__(self.___2))
    		self.channel3.SetEvent(ui.__mem_func__(self.___3))
    		self.channel4.SetEvent(ui.__mem_func__(self.___4))
    	
    
    	
    	def	___1(self):
    		snd.PlaySound("sound/ui/click.wav")
    		ch = "1"
    		self.__OnChangeChannel(ch)
    		
    	def	___2(self):
    		snd.PlaySound("sound/ui/click.wav")
    		ch = "2"
    		self.__OnChangeChannel(ch)
    		
    	def	___3(self):
    		snd.PlaySound("sound/ui/click.wav")
    		ch = "3"
    		self.__OnChangeChannel(ch)
    		
    	def	___4(self):
    		snd.PlaySound("sound/ui/click.wav")
    		ch = "4"
    		self.__OnChangeChannel(ch)
    		
    	def __IsSpecialMap(self):
    		dis_maps = [
    			"season1/metin2_map_oxevent",
    			"season2/metin2_map_guild_inside01",
    			"season2/metin2_map_empirewar01",
    			"season2/metin2_map_empirewar02",
    			"season2/metin2_map_empirewar03",
    			"metin2_map_dragon_timeattack_01",
    			"metin2_map_dragon_timeattack_02",
    			"metin2_map_dragon_timeattack_03",
    			"metin2_map_skipia_dungeon_boss",
    			"metin2_map_skipia_dungeon_boss2",
    			"metin2_map_devilsCatacomb",
    			"metin2_map_deviltower1",
    			"metin2_map_t1",
    			"metin2_map_t2",
    			"metin2_map_t3",
    			"metin2_map_t4",
    			"metin2_map_t5",
    			"metin2_map_wedding_01",
    			"metin2_map_duel",
    			"metin2_map_orclabyrinth",
    			"metin2_map_n_flame_dungeon_01",
    			"metin2_map_n_snow_dungeon_01"
    		]
    		if str(background.GetCurrentMapName()) in dis_maps:
    			return TRUE
    		return FALSE
    		
    	def __OnChangeChannel(self, ch):
    		ServerStateChecker.Update()
    		channel = net.GetServerInfo()[-1]
    #		channelnum = filter(str.isdigit, channel)
    		if ch == channel:
    			chat.AppendChat(chat.CHAT_TYPE_INFO, "You're already in the selected channel!")
    			return
    		if self.__IsSpecialMap():
    			chat.AppendChat(chat.CHAT_TYPE_INFO, "Sorry, This Is One of spiecal maps which you cannot change channel while you in it!")
    			return
    		net.SendChatPacket("/channel "+ str(ch))
    		self.Close()
    		
    	def Close(self):
    		constInfo.channel = 0
    		self.Hide()
    		return TRUE
    		
    	def OnPressEscapeKey(self):
    		constInfo.channel = 0
    		self.Hide()
    		return TRUE
    		

     

    3: change systemdialog.py in uiscript with this

     

    import uiScriptLocale
    
    ROOT = "d:/ymir work/ui/public/"
    
    window = {
    	"name" : "SystemDialog",
    	"style" : ("float",),
    
    	"x" : SCREEN_WIDTH/2 - 100,
    	"y" : SCREEN_HEIGHT/2 - 114,
    
    	"width" : 200,
    	"height" : 298,
    
    	"children" :
    	(
    		{
    			"name" : "board",
    			"type" : "thinboard",
    
    			"x" : 0,
    			"y" : 0,
    
    			"width" : 200,
    			"height" : 298,
    
    			"children" :
    			(
    				{
    					"name" : "Change_Channel",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 17,
    
    					"text" : uiScriptLocale.SYSTEM_CHANGE_CH,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "help_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 47,
    
    					"text" : uiScriptLocale.SYSTEM_HELP,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    
    				{
    					"name" : "system_option_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 97,
    
    					"text" : uiScriptLocale.SYSTEMOPTION_TITLE,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "game_option_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 127,
    
    					"text" : uiScriptLocale.GAMEOPTION_TITLE,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "change_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 157,
    
    					"text" : uiScriptLocale.SYSTEM_CHANGE,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "logout_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 187,
    
    					"text" : uiScriptLocale.SYSTEM_LOGOUT,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "exit_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 217,
    
    					"text" : uiScriptLocale.SYSTEM_EXIT,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    				{
    					"name" : "cancel_button",
    					"type" : "button",
    
    					"x" : 10,
    					"y" : 257,
    
    					"text" : uiScriptLocale.CANCEL,
    
    					"default_image" : ROOT + "XLarge_Button_01.sub",
    					"over_image" : ROOT + "XLarge_Button_02.sub",
    					"down_image" : ROOT + "XLarge_Button_03.sub",
    				},
    			),
    		},
    	),
    }
    

     

    4: channel.py in upscript folder // i forgot it

    [spoiler]

    import item
    import app
    import uiScriptLocale
    
    UI = "d:/ymir work/ui/"
    PUBLIC = "d:/ymir work/ui/public/"
    
    window = {
    	"name" : "Channel_Switcher",
    	
    	"x" : SCREEN_WIDTH/2 ,
    	"y" : SCREEN_HEIGHT/2 ,
    	
    	"style" : ("movable", "float",),
    	
    	"width" : 150,
    	"height" : 150,	
    	
    	"children" :
    	(
    		{
    			"name" : "board",
    			"type" : "board",
    			"style" : ("attach",),
    			
    			"x" : 0,
    			"y" : 0,
    			
    			"width" : 150,
    			"height" : 150,
    			
    			"children" :
    			(
    				{
    					"name" : "TitleBar",
    					"type" : "titlebar",
    					"style" : ("attach",),
    					
    					"x" : 8,
    					"y" : 7,
    					
    					"width" : 135,
    					
    					"children" :
    					(
    						{ 
    							"name":"TitleName",
    							"type":"text",
    
    							"x":65,
    							"y":3,
    
    							"text":uiScriptLocale.SYSTEM_CHANGE_CH,
    							"text_horizontal_align":"center"
    							
    						},
    					),
    				},
    				{
    					"name" : "Channel_1",
    					"type" : "button",
    					
    					"x" : 50,
    					"y" : 35,
    					
    					"text" : "Channel 1",
    					
    					"default_image" : PUBLIC + "middle_button_01.sub",
    					"over_image" : PUBLIC + "middle_button_02.sub",
    					"down_image" : PUBLIC + "middle_button_03.sub",
    				},
    				
    				{
    					"name" : "Channel_2",
    					"type" : "button",
    					
    					"x" : 50,
    					"y" : 60,
    					
    					"text" : "Channel 2",
    					
    					"default_image" : PUBLIC + "middle_button_01.sub",
    					"over_image" : PUBLIC + "middle_button_02.sub",
    					"down_image" : PUBLIC + "middle_button_03.sub",
    				},
    				{
    					"name" : "Channel_3",
    					"type" : "button",
    					
    					"x" : 50,
    					"y" : 85,
    					
    					"text" : "Channel 3",
    					
    					"default_image" : PUBLIC + "middle_button_01.sub",
    					"over_image" : PUBLIC + "middle_button_02.sub",
    					"down_image" : PUBLIC + "middle_button_03.sub",
    				},
    				{
    					"name" : "Channel_4",
    					"type" : "button",
    					
    					"x" : 50,
    					"y" : 110,
    					
    					"text" : "Channel 4",
    					
    					"default_image" : PUBLIC + "middle_button_01.sub",
    					"over_image" : PUBLIC + "middle_button_02.sub",
    					"down_image" : PUBLIC + "middle_button_03.sub",
    				},
    			),
    		},
    	),
    }
    
    
    

    [/spoiler]

    and finally go to constnfo.py in root and write this

    channel = 0

    and the python part is over <3

  5. Hello! If someone can send me the download link via pm (too lazy to search) I'll create a vm for you! Seems like it's a bit difficult and I like difficulty :ph34r:

     

    Oohh aaand that's the wrong section. You may want to post something like that into question section for the future, okay? :P

     

    Aaaand I'm dumb. First post has the source. Oh, crazy me. I'm downloading it right now and I'm onto it! :) Give me some cheers!

    ​Good luck making it to work and ty for offering to help us :)

    ​Sorry that it didn't work out at all. I've managed to set up a machine and compile it but it's way too big to upload :/

    ​try to shrink the VDI with this

    go to this location "C:\Program Files\Oracle\VirtualBox"

    and make new file name it what ever you want but with cmd extension and type in this

    VBoxManage.exe modifyhd --compact "location of the VDI image"
    
    EX:
        VBoxManage.exe modifyhd --compact "d:\9.2VM\Freebsd9.2.vdi"

     

     

  6. #Fixed <3

    open MapOutdoorRenderHTP.cpp from gamelib from client source and change this

    	if (GetAsyncKeyState(VK_CAPITAL))
    	{
    		CSpeedTreeWrapper::ms_bSelfShadowOn = false;
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_GAUSSIANCUBIC);
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_GAUSSIANCUBIC);
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MIPFILTER, D3DTEXF_GAUSSIANCUBIC);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MINFILTER, D3DTEXF_GAUSSIANCUBIC);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MAGFILTER, D3DTEXF_GAUSSIANCUBIC);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MIPFILTER, D3DTEXF_GAUSSIANCUBIC);
    	}
    	else
    	{
    		CSpeedTreeWrapper::ms_bSelfShadowOn = true;
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_LINEAR);
    		STATEMANAGER.SetSamplerState(0, D3DSAMP_MIPFILTER, D3DTEXF_LINEAR);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MINFILTER, D3DTEXF_LINEAR);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MAGFILTER, D3DTEXF_LINEAR);
    		STATEMANAGER.SetSamplerState(1, D3DSAMP_MIPFILTER, D3DTEXF_LINEAR);
    	}
    

    with this

    	CSpeedTreeWrapper::ms_bSelfShadowOn = false;
    	STATEMANAGER.SetSamplerState(0, D3DSAMP_MINFILTER, D3DTEXF_GAUSSIANCUBIC);
    	STATEMANAGER.SetSamplerState(0, D3DSAMP_MAGFILTER, D3DTEXF_GAUSSIANCUBIC);
    	STATEMANAGER.SetSamplerState(0, D3DSAMP_MIPFILTER, D3DTEXF_GAUSSIANCUBIC);
    	STATEMANAGER.SetSamplerState(1, D3DSAMP_MINFILTER, D3DTEXF_GAUSSIANCUBIC);
    	STATEMANAGER.SetSamplerState(1, D3DSAMP_MAGFILTER, D3DTEXF_GAUSSIANCUBIC);
    	STATEMANAGER.SetSamplerState(1, D3DSAMP_MIPFILTER, D3DTEXF_GAUSSIANCUBIC);

    or this

    	CSpeedTreeWrapper::ms_bSelfShadowOn = true;
    	STATEMANAGER.SetBestFiltering(0);
    	STATEMANAGER.SetBestFiltering(1);

     

  7. Use this batchfile to collecting the source files into rar archive:

    @echo off
    
    if %1=="" goto :eof
    
    set SAVESTAMP=%DATE:-=%%TIME::=%
    set SAVESTAMP=%SAVESTAMP: =0%
    set SAVESTAMP=%SAVESTAMP:,=%
    
    if not exist "%~1_backup" (
    	mkdir "%~1_backup%" 
    	echo make dir: "%~n1_backup"
    )
    
    echo backup name: "%~n1_%SAVESTAMP%"
    
    "c:Program FilesWinRARWinRAR.exe" a -r "%~1_backup/%~n1_%SAVESTAMP%.rar" -m5 -ep1 -n*.h -n*.c -n*.cc -n*.cpp -n*.hpp -n*.sln -n*.suo -n*.vssscc -n*.vcproj -n*.vcxproj -n*.vspscc -n*.cur -n*.ico -n*.manifest -n*.filters -n*.user -n*.aps -n*.rc -n*.vspscc "%~1"
    
    echo "%~n1_backup/%~n1_%SAVESTAMP%.rar"
    
    pause
    
    :eof

    03bcaf2486.png

     

    Usage:

    cmd# backup Server[ENTER]

    w8 until done and press a button.

     

    ps. This batch-script made by Terenzo.

    ​this is wrong :/

    here is working one

    @echo off
    
    if %1=="" goto :eof
    
    set SAVESTAMP=%DATE:-=%%TIME::=%
    set SAVESTAMP=%SAVESTAMP: =0%
    set SAVESTAMP=%SAVESTAMP:,=%
    
    if not exist "%~1_backup" (
    	mkdir "%~1_backup%" 
    	echo make dir: "%~n1_backup"
    )
    
    echo backup name: "%~n1_%SAVESTAMP%"
    
    "C:\Program Files\WinRAR\WinRAR.exe" a -r "%~1_backup/%~1.rar" -m5 -ep1 *.h *.lib *.c *.cc *.cpp *.hpp *.sln *.suo *.vssscc *.vcproj *.vcxproj *.vspscc *.cur *.ico *.manifest *.filters *.user *.aps *.rc *.vspscc "%~1"
    
    echo "%~n1_backup/%~n1_%SAVESTAMP%.rar"
    
    pause
    
    :eof

     

×
×
  • 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.