Jump to content

gweilo321

Inactive Member
  • Posts

    45
  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by gweilo321

  1. Nope, still the same. I tried but im suing send_letter_ex for every other quest i have and it works fine
  2. Thanks for the quick reply! For some reason still the message doesnt pop up. The letter does come but when i click the letter the message doesnt pop up. Do you maybe know the reason why? No error while installing the quest +edit Also the i am receiving the letter everytime i relog.
  3. Why is this not working, im tryingto get a letter at he beginning of the game only. i get the letter but when i open it nothing happens quest start begin state start begin when login begin if pc.getqf("starter1") == 0 then pc.setqf("starter1",1) send_letter_ex("Hello", "ex,blink", "scroll_open.tga") set_state( starter ) else return end end end state starter begin when button or info begin say("blabla") end end end
  4. Hi guys, im trying to do something like boxes for mounts. Basically the mount arent tradeable, but i want to put them in a box by NPC. But if the mounts for example has 3 days left i want to keep that time. How can i put the mount into a box with the same time that it was put in and then take it out with the same time. If that makes sense?
  5. Hi guys how can i add to a sidepanel opening shop without needing the item?
  6. If i start the server i keep getting the eror. Its like DB wont even start SYSERR: Nov 11 13:52:36 :: socket_accept: accept: Software caused connection abort (fd 19) SYSERR: Nov 11 13:52:36 :: Process: FDWATCH: peer null in event: ident 20 SYSERR: Nov 11 13:52:36 :: socket_accept: accept: Software caused connection abort (fd 19) Ok .. i just solved it.. I deleted some lines from questlib.lua and it fixed. Looks like questlib was crashing my server
  7. Theres no char.h as i am doing this in a client source. In InstanceBaseEffect.cpp and i am changing this code void CInstanceBase::UpdateTextTailLevel(DWORD level) to this void CInstanceBase::UpdateTextTailLevel(DWORD level) { static D3DXCOLOR s_kLevelColor = D3DXCOLOR(152.0f/255.0f, 255.0f/255.0f, 51.0f/255.0f, 1.0f); char szText[256]; sprintf(szText, "Lv %d", level); CPythonTextTail::Instance().AttachLevel(GetVirtualID(), szText, s_kLevelColor); if (IsGameMaster()) //GM { sprintf(szText, "|cff87CEEB[DEV]|r Lv %d ", level); CPythonTextTail::Instance().AttachLevel(GetVirtualID(), szText, s_kLevelColor); } } But instead of isGameMaster i wanna change it to check ingame nickname. so i basically want something like this if (ch->GetName() == "Name") { sprintf(szText, "|cff87CEEB[DEV]|r Lv %d ", level); CPythonTextTail::Instance().AttachLevel(GetVirtualID(), szText, s_kLevelColor); } but its not working, has anyone got an idea how can i do it?
  8. I just want to add [GAMEMASTER] [MOD] nexto Name in Game. So i just want to define someones name in game and set it. Anyone got an idea how can i get someones ingame name put it in a if?
  9. Hi guys im looking for a function in c++ source to get players name. I tried " if((chrGetName)== "name") " but its not working, anyone got an idea whats the function?
  10. I obviously havent showed the ip but its in the file. When i add this code nothing is showing in login window
  11. I dont get it im keep trying to add its not working
  12. Sorry... How do i simply add a channel status checker i tried the one from standard intrologin but it didnt work :/ import dbg import app import net import ui import ime import snd import wndMgr import musicInfo import serverInfo import systemSetting import ServerStateChecker import localeInfo import constInfo import uiCommon import time import serverCommandParser import ime import uiScriptLocale import os from _weakref import proxy SERVER_IP = "" CH1_PORT = 13000 CH2_PORT = 13001 CH3_PORT = 13002 CH4_PORT = 13003 LOGIN = 11002 SERVER_NAME = "" class LoginWindow(ui.ScriptWindow): def __init__(self, stream): ui.ScriptWindow.__init__(self) net.SetPhaseWindow(net.PHASE_WINDOW_LOGIN, self) net.SetAccountConnectorHandler(self) self.stream = stream def __del__(self): ui.ScriptWindow.__del__(self) net.ClearPhaseWindow(net.PHASE_WINDOW_LOGIN, self) net.SetAccountConnectorHandler(0) def Open(self): self.loginFailureMsgDict={ "ALREADY" : localeInfo.LOGIN_FAILURE_ALREAY, "NOID" : localeInfo.LOGIN_FAILURE_NOT_EXIST_ID, "WRONGPWD" : localeInfo.LOGIN_FAILURE_WRONG_PASSWORD, "FULL" : localeInfo.LOGIN_FAILURE_TOO_MANY_USER, "SHUTDOWN" : localeInfo.LOGIN_FAILURE_SHUTDOWN, "REPAIR" : localeInfo.LOGIN_FAILURE_REPAIR_ID, "BLOCK" : localeInfo.LOGIN_FAILURE_BLOCK_ID, "WRONGMAT" : localeInfo.LOGIN_FAILURE_WRONG_MATRIX_CARD_NUMBER, "QUIT" : localeInfo.LOGIN_FAILURE_WRONG_MATRIX_CARD_NUMBER_TRIPLE, "BESAMEKEY" : localeInfo.LOGIN_FAILURE_BE_SAME_KEY, "NOTAVAIL" : localeInfo.LOGIN_FAILURE_NOT_AVAIL, "NOBILL" : localeInfo.LOGIN_FAILURE_NOBILL, "BLKLOGIN" : localeInfo.LOGIN_FAILURE_BLOCK_LOGIN, "WEBBLK" : localeInfo.LOGIN_FAILURE_WEB_BLOCK, } self.loginFailureFuncDict = { "WRONGPWD" : localeInfo.LOGIN_FAILURE_WRONG_PASSWORD, "WRONGMAT" : localeInfo.LOGIN_FAILURE_WRONG_MATRIX_CARD_NUMBER, "QUIT" : app.Exit, } self.SetSize(wndMgr.GetScreenWidth(), wndMgr.GetScreenHeight()) self.SetWindowName("LoginWindow") self.__LoadScript("loginwindow_new/loginwindow.py") if musicInfo.loginMusic != "": snd.SetMusicVolume(systemSetting.GetMusicVolume()) snd.FadeInMusic("BGM/" + musicInfo.loginMusic) snd.SetSoundVolume(systemSetting.GetSoundVolume()) ime.AddExceptKey(91) ime.AddExceptKey(93) self.SetChannel(0) self.Show() app.ShowCursor() def Close(self): if musicInfo.loginMusic != "" and musicInfo.selectMusic != "": snd.FadeOutMusic("BGM/"+musicInfo.loginMusic) if self.stream.popupWindow: self.stream.popupWindow.Close() self.Hide() app.HideCursor() ime.ClearExceptKey() def OnConnectFailure(self): snd.PlaySound("sound/ui/loginfail.wav") self.PopupNotifyMessage(localeInfo.LOGIN_CONNECT_FAILURE, self.EmptyFunc) def OnHandShake(self): snd.PlaySound("sound/ui/loginok.wav") self.PopupDisplayMessage(localeInfo.LOGIN_CONNECT_SUCCESS) def OnLoginStart(self): self.PopupDisplayMessage(localeInfo.LOGIN_PROCESSING) def OnLoginFailure(self, error): try: loginFailureMsg = self.loginFailureMsgDict[error] except KeyError: loginFailureMsg = localeInfo.LOGIN_FAILURE_UNKNOWN + error loginFailureFunc = self.loginFailureFuncDict.get(error, self.EmptyFunc) self.PopupNotifyMessage(loginFailureMsg, loginFailureFunc) snd.PlaySound("sound/ui/loginfail.wav") def __LoadScript(self, fileName): try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, fileName) except: import exception exception.Abort("LoginWindow.__LoadScript.LoadObject") try: self.idEditLine = self.GetChild("id") self.pwdEditLine = self.GetChild("pwd") self.loginButton = self.GetChild("login_button") self.exitButton = self.GetChild("exit_button") self.websiteButton = self.GetChild("website_button") self.parolauitataButton = self.GetChild("parolauitata_button") self.registerButton = self.GetChild("register_button") self.SaveLogin1 = self.GetChild("SaveButton1") self.LoadLogin1 = self.GetChild("LoadButton1") self.SaveLogin2 = self.GetChild("SaveButton2") self.LoadLogin2 = self.GetChild("LoadButton2") self.SaveLogin3 = self.GetChild("SaveButton3") self.LoadLogin3 = self.GetChild("LoadButton3") self.SaveLogin4 = self.GetChild("SaveButton4") self.LoadLogin4 = self.GetChild("LoadButton4") self.channelButton = { 0 : self.GetChild("ch1"), 1 : self.GetChild("ch2"), 2 : self.GetChild("ch3"), 3 : self.GetChild("ch4")} except: import exception exception.Abort("LoginWindow.__LoadScript.BindObject") for (channelID, channelButtons) in self.channelButton.items(): channelButtons.SetEvent(ui.__mem_func__(self.SetChannel), channelID) self.loginButton.SetEvent(ui.__mem_func__(self.__OnClickLoginButton)) self.exitButton.SetEvent(ui.__mem_func__(self.OnPressExitKey)) self.websiteButton.SetEvent(ui.__mem_func__(self.GoWebSite)) self.parolauitataButton.SetEvent(ui.__mem_func__(self.GoParolaUitata)) self.registerButton.SetEvent(ui.__mem_func__(self.GoRegister)) self.SaveLogin1.SetEvent(ui.__mem_func__(self.__SaveLogin1)) self.LoadLogin1.SetEvent(ui.__mem_func__(self.__LoadLogin1)) self.SaveLogin2.SetEvent(ui.__mem_func__(self.__SaveLogin2)) self.LoadLogin2.SetEvent(ui.__mem_func__(self.__LoadLogin2)) self.SaveLogin3.SetEvent(ui.__mem_func__(self.__SaveLogin3)) self.LoadLogin3.SetEvent(ui.__mem_func__(self.__LoadLogin3)) self.SaveLogin4.SetEvent(ui.__mem_func__(self.__SaveLogin4)) self.LoadLogin4.SetEvent(ui.__mem_func__(self.__LoadLogin4)) self.idEditLine.SetReturnEvent(ui.__mem_func__(self.pwdEditLine.SetFocus)) self.idEditLine.SetTabEvent(ui.__mem_func__(self.pwdEditLine.SetFocus)) self.pwdEditLine.SetReturnEvent(ui.__mem_func__(self.__OnClickLoginButton)) self.pwdEditLine.SetTabEvent(ui.__mem_func__(self.idEditLine.SetFocus)) self.idEditLine.SetFocus() def SetChannel(self, ch): for key, button in self.channelButton.items(): button.SetUp() self.channelButton[ch].Down() self.stream.SetConnectInfo(SERVER_IP, self.ChannelPort(ch, 0), SERVER_IP, self.ChannelPort("LOGIN")) net.SetMarkServer(SERVER_IP, self.ChannelPort("LOGO")) app.SetGuildMarkPath("10.tga") app.SetGuildSymbolPath("10") net.SetServerInfo(self.ChannelPort(ch, 2)) def ChannelPort(self, ch, value=0): channel = { 0 : CH1_PORT, 1 : CH2_PORT, 2 : CH3_PORT, 3 : CH4_PORT,} if ch == "LOGIN": return LOGIN elif ch == "LOGO": return channel[0] elif value == 2: return SERVER_NAME + ", CH%s" % (ch+1) else: return channel[ch] def Connect(self, id, pwd): if constInfo.SEQUENCE_PACKET_ENABLE: net.SetPacketSequenceMode() constInfo.LastAccount = id.lower() self.stream.popupWindow.Close() self.stream.popupWindow.Open(localeInfo.LOGIN_CONNETING, self.EmptyFunc, localeInfo.UI_CANCEL) self.stream.SetLoginInfo(id, pwd) self.stream.Connect() def PopupDisplayMessage(self, msg): self.stream.popupWindow.Close() self.stream.popupWindow.Open(msg) def PopupNotifyMessage(self, msg, func=0): if not func: func = self.EmptyFunc self.stream.popupWindow.Close() self.stream.popupWindow.Open(msg, func, localeInfo.UI_OK) def OnPressExitKey(self): if self.stream.popupWindow: self.stream.popupWindow.Close() self.stream.SetPhaseWindow(0) return TRUE ## BUTOANE PENTRU LINKURI ## def GoWebSite(self): import os os.system('@echo off && explorer "https:///"') return TRUE def GoParolaUitata(self): import os os.system('@echo off && explorer "https:///"') return TRUE def GoRegister(self): import os os.system('@echo off && explorer "https:///"') return TRUE ############################ def EmptyFunc(self): pass def __OnClickLoginButton(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(localeInfo.LOGIN_INPUT_ID, self.EmptyFunc) return if len(pwd)==0: self.PopupNotifyMessage(localeInfo.LOGIN_INPUT_PASSWORD, self.EmptyFunc) return self.Connect(id, pwd) def __SaveLogin1(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_ID, self.SetIDEditLineFocus) return if len(pwd)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_PASSWORD, self.SetPasswordEditLineFocus) return open('config/Konto1.SyS', 'w').write('%s\t%s' % (id, pwd)) self.PopupNotifyMessage("Pomyœlnie zapisano dane.") def __LoadLogin1(self): if os.path.exists("config/Konto1.SyS"): logininfo = open("config/Konto1.SyS", "r").read().split() self.idEditLine.SetText(logininfo[0]) self.pwdEditLine.SetText(logininfo[1]) else: self.PopupNotifyMessage("Nie zapisano tutaj konta.") def __SaveLogin2(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_ID, self.SetIDEditLineFocus) return if len(pwd)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_PASSWORD, self.SetPasswordEditLineFocus) return open('config/Konto2.SyS', 'w').write('%s\t%s' % (id, pwd)) self.PopupNotifyMessage("Pomyœlnie zapisano dane.") def __LoadLogin2(self): if os.path.exists("config/Konto2.SyS"): logininfo = open("config/Konto2.SyS", "r").read().split() self.idEditLine.SetText(logininfo[0]) self.pwdEditLine.SetText(logininfo[1]) else: self.PopupNotifyMessage("Nie zapisano tutaj konta.") def __SaveLogin3(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_ID, self.SetIDEditLineFocus) return if len(pwd)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_PASSWORD, self.SetPasswordEditLineFocus) return open('config/Konto3.SyS', 'w').write('%s\t%s' % (id, pwd)) self.PopupNotifyMessage("Pomyœlnie zapisano dane.") def __LoadLogin3(self): if os.path.exists("config/Konto3.SyS"): logininfo = open("config/Konto3.SyS", "r").read().split() self.idEditLine.SetText(logininfo[0]) self.pwdEditLine.SetText(logininfo[1]) else: self.PopupNotifyMessage("Nie zapisano tutaj konta.") def __SaveLogin4(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_ID, self.SetIDEditLineFocus) return if len(pwd)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_PASSWORD, self.SetPasswordEditLineFocus) return open('config/Konto4.SyS', 'w').write('%s\t%s' % (id, pwd)) self.PopupNotifyMessage("Pomyœlnie zapisano dane.") def __LoadLogin4(self): if os.path.exists("config/Konto4.SyS"): logininfo = open("config/Konto4.SyS", "r").read().split() self.idEditLine.SetText(logininfo[0]) self.pwdEditLine.SetText(logininfo[1]) else: self.PopupNotifyMessage("Nie zapisano tutaj konta.") def __OnClickSaveButton(self): id = self.idEditLine.GetText() pwd = self.pwdEditLine.GetText() if len(id)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_ID, self.SetIDEditLineFocus) return if len(pwd)==0: self.PopupNotifyMessage(locale.LOGIN_INPUT_PASSWORD, self.SetPasswordEditLineFocus) return
  13. Hi i ve added new intrlogin.py but in this one it doesnt show Online or Offline channel. Could someone help me out to just simply add " Online " and "offline status on channels please?
×
×
  • 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.