Jump to content

Search the Community

Showing results for tags 'c++/python' in content posted in C++ / Python / Server.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Forum board
    • M2Zone.tech
  • Strefa gracza
    • Server presentations
    • Discussions, Questions and Problems
  • Create private server
    • Pytania i Problemy - bez logowania
    • Problems and Questions
    • Cooperation
    • Tutorials / Video
    • C++ / Python / Server
    • Sources / Serverfiles / Clients
    • Homepage / Board
    • Quests
    • 2D Graphics
    • 3D Graphics
    • Recycling
  • Marketplace
    • Rynek - (Kupię, Sprzedam, Zamienię i Zlecę)
    • Archiwum
  • Hydepark
    • About all
    • Introduce yourself
    • My Creativity / Media
  • Others
    • Blokady i Ostrzeżenia
    • Trash

Categories

  • Programs
  • Plechito.com
    • Events
    • Maps
    • Mounts
    • Equipments
    • Monsters
    • NPC

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Sex


Country


Facebook


Discord


Telegram


Gadu-Gadu

Found 156 results

  1. Cześć, zapłaciłem pieniążki oszustowi Ikarusowi. Wysłałem autorowi obejście, tłumacząc by sobie zabezpieczył to zamiast mi podziękować mnie zbanował xD Straciłem support, możliwe że te sklepy mają kopiowanie itemów. SKLEPY OFFLINE.rar Obejście licencji #include "stdafx.h" #include "Offlineshop2.h" bool Offlineshop_InitializeLibrary(const char * szUser, const char* szPassword) { return true; }; void Offlineshop_CleanUpLibrary() { return; }; bool TestLibrary() { return true; }; size_t Offlineshop_GetMapCount() { return 1; }; //1 void Offlineshop_GetNewPos(size_t index, size_t ent_count, long* x, long* y) { //todo *x = rand() % (83100 - 76400) + 76400; *y = rand() % (328400 - 320200) + 320200; // 76400 320200 // 83100 328400 //*x = 78800; //*y = 323900; }; // 0 0 -26472 -26468 void Offlineshop_GetMapIndex(size_t index, int* map_index) { *map_index = 2; }; // 0 2 bool Offlineshop_CheckPositionDistance(long x1, long y1, long x2, long y2) { //todo return true; }; // 80029 324042 79408 323601 Na 99% czegoś brakuje, dajcie mi znać to na bieżąco będę Wam wyciągał. Publikuje te sklepy tylko i wyłącznie dlatego że zostałem oszukany, w innym przypadku nie publikuje innych prac. Doceniam kogoś pracę.
  2. Poprawiłem co się dało, testowane - działa. 1. Otwórz client/UserInterface/Locale_inc.h i dodaj w nim: #define ENABLE_CUBE_RENEWAL 2. Otwórz client/UserInterface/packet.h i znajdź w nim: HEADER_CG_KEY_AGREEMENT = 0xfb, // _IMPROVED_PACKET_ENCRYPTION_ HEADER_CG_TIME_SYNC = 0xfc, HEADER_CG_CLIENT_VERSION = 0xfd, HEADER_CG_CLIENT_VERSION2 = 0xf1, HEADER_CG_PONG = 0xfe, HEADER_CG_HANDSHAKE = 0xff, Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL HEADER_CG_CUBE_RENEWAL = 215, #endif Znajdź: HEADER_GC_KEY_AGREEMENT_COMPLETED = 0xfa, // _IMPROVED_PACKET_ENCRYPTION_ HEADER_GC_KEY_AGREEMENT = 0xfb, // _IMPROVED_PACKET_ENCRYPTION_ HEADER_GC_HANDSHAKE_OK = 0xfc, // 252 HEADER_GC_PHASE = 0xfd, // 253 HEADER_GC_BINDUDP = 0xfe, // 254 HEADER_GC_HANDSHAKE = 0xff, // 255 Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL HEADER_GC_CUBE_RENEWAL = 217, #endif Znajdź: #pragma pack(pop) Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL enum { CUBE_RENEWAL_SUB_HEADER_OPEN_RECEIVE, CUBE_RENEWAL_SUB_HEADER_CLEAR_DATES_RECEIVE, CUBE_RENEWAL_SUB_HEADER_DATES_RECEIVE, CUBE_RENEWAL_SUB_HEADER_DATES_LOADING, CUBE_RENEWAL_SUB_HEADER_MAKE_ITEM, CUBE_RENEWAL_SUB_HEADER_CLOSE, }; typedef struct packet_send_cube_renewal { BYTE header; BYTE subheader; DWORD index_item; DWORD count_item; DWORD index_item_improve; } TPacketCGCubeRenewalSend; typedef struct dates_cube_renewal { DWORD npc_vnum; DWORD index; DWORD vnum_reward; int count_reward; bool item_reward_stackable; DWORD vnum_material_1; int count_material_1; DWORD vnum_material_2; int count_material_2; DWORD vnum_material_3; int count_material_3; DWORD vnum_material_4; int count_material_4; DWORD vnum_material_5; int count_material_5; int gold; int percent; char category[100]; } TInfoDateCubeRenewal; typedef struct packet_receive_cube_renewal { packet_receive_cube_renewal(): header(HEADER_GC_CUBE_RENEWAL) {} BYTE header; BYTE subheader; TInfoDateCubeRenewal date_cube_renewal; } TPacketGCCubeRenewalReceive; #endif 3. Otwórz client/UserInterface/PythonApplication.h i znajdź w nim: #include "PythonExchange.h" #include "PythonChat.h" Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL #include "PythonCubeRenewal.h" #endif Znajdź: CGraphicDevice m_grpDevice; CNetworkDevice m_netDevice; CPythonSystem m_pySystem; Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL CPythonCubeRenewal m_pyCubeRenewal; #endif 4. Otwórz client/UserInterface/PythonApplicationModule.cpp i znajdź w nim: #ifdef ENABLE_COSTUME_SYSTEM PyModule_AddIntConstant(poModule, "ENABLE_COSTUME_SYSTEM", 1); #else PyModule_AddIntConstant(poModule, "ENABLE_COSTUME_SYSTEM", 0); #endif Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL PyModule_AddIntConstant(poModule, "ENABLE_CUBE_RENEWAL", 1); #else PyModule_AddIntConstant(poModule, "ENABLE_CUBE_RENEWAL", 0); #endif 5. Otwórz client/UserInterface/PythonNetworkStream.cpp i znajdź w nim: Set(HEADER_GC_DRAGON_SOUL_REFINE, CNetworkPacketHeaderMap::TPacketType(sizeof(TPacketGCDragonSoulRefine), STATIC_SIZE_PACKET)); Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL Set(HEADER_GC_CUBE_RENEWAL, CNetworkPacketHeaderMap::TPacketType(sizeof(TPacketGCCubeRenewalReceive), STATIC_SIZE_PACKET)); #endif 6. Otwórz client/UserInterface/PythonNetworkStream.h i znajdź w nim: // ETC DWORD GetMainActorVID(); DWORD GetMainActorRace(); DWORD GetMainActorEmpire(); DWORD GetMainActorSkillGroup(); void SetEmpireID(DWORD dwEmpireID); DWORD GetEmpireID(); void __TEST_SetSkillGroupFake(int iIndex); Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL bool CubeRenewalMakeItem(int index_item, int count_item, int index_item_improve); bool CubeRenewalClose(); bool RecvCubeRenewalPacket(); #endif 7. Otwórz client/UserInterface/PythonNetworkStreamPhaseGame.cpp i znajdź w nim: #include "PythonTextTail.h" #include "PythonItem.h" #include "PythonChat.h" Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL #include "PythonCubeRenewal.h" #endif Znajdź: case HEADER_GC_DRAGON_SOUL_REFINE: ret = RecvDragonSoulRefine(); break; Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL case HEADER_GC_CUBE_RENEWAL: ret = RecvCubeRenewalPacket(); break; #endif Znajdź: bool CPythonNetworkStream::SendDragonSoulRefinePacket(BYTE bRefineType, TItemPos* pos) { TPacketCGDragonSoulRefine pk; pk.header = HEADER_CG_DRAGON_SOUL_REFINE; pk.bSubType = bRefineType; memcpy (pk.ItemGrid, pos, sizeof (TItemPos) * DS_REFINE_WINDOW_MAX_NUM); if (!Send(sizeof (pk), &pk)) { return false; } return true; } Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL bool CPythonNetworkStream::CubeRenewalMakeItem(int index_item, int count_item, int index_item_improve) { if (!__CanActMainInstance()) return true; TPacketCGCubeRenewalSend packet; packet.header = HEADER_CG_CUBE_RENEWAL; packet.subheader = CUBE_RENEWAL_SUB_HEADER_MAKE_ITEM; packet.index_item = index_item; packet.count_item = count_item; packet.index_item_improve = index_item_improve; if (!Send(sizeof(TPacketCGCubeRenewalSend), &packet)) { Tracef("CPythonNetworkStream::CubeRenewalMakeItem Error\n"); return false; } return SendSequence(); } bool CPythonNetworkStream::CubeRenewalClose() { if (!__CanActMainInstance()) return true; TPacketCGCubeRenewalSend packet; packet.header = HEADER_CG_CUBE_RENEWAL; packet.subheader = CUBE_RENEWAL_SUB_HEADER_CLOSE; if (!Send(sizeof(TPacketCGCubeRenewalSend), &packet)) { Tracef("CPythonNetworkStream::CubeRenewalClose Error\n"); return false; } return SendSequence(); } bool CPythonNetworkStream::RecvCubeRenewalPacket() { TPacketGCCubeRenewalReceive CubeRenewalPacket; if (!Recv(sizeof(CubeRenewalPacket), &CubeRenewalPacket)) return false; switch (CubeRenewalPacket.subheader) { case CUBE_RENEWAL_SUB_HEADER_OPEN_RECEIVE: { PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_GAME], "BINARY_CUBE_RENEWAL_OPEN", Py_BuildValue("()")); } break; case CUBE_RENEWAL_SUB_HEADER_DATES_RECEIVE: { CPythonCubeRenewal::Instance().ReceiveList(CubeRenewalPacket.date_cube_renewal); } break; case CUBE_RENEWAL_SUB_HEADER_DATES_LOADING: { CPythonCubeRenewal::Instance().LoadingList(); } break; case CUBE_RENEWAL_SUB_HEADER_CLEAR_DATES_RECEIVE: { CPythonCubeRenewal::Instance().ClearList(); } break; } return true; } #endif 8. Otwórz client/UserInterface/StdAfx.h i znajdź w nim: void initsafebox(); void initguild(); void initMessenger(); Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL void intcuberenewal(); #endif 9. Otwórz client/UserInterface/UserInterface.cpp i znajdź w nim: initsafebox(); initguild(); initServerStateChecker(); Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL intcuberenewal(); #endif 10. Dodaj do UserInterface i projektu: PythonCubeRenewal.cpp PythonCubeRenewal.h 11. Otwórz game/service.h i dodaj w nim: #define ENABLE_CUBE_RENEWAL 12. Otwórz game/char.h i znajdź w nim: #include "cube.h" Dodaj pod: #include "cube_renewal.h" 13. Otwórz game/cmd_general.cpp i znajdź w nim: ACMD(do_cube) Zamień całość na: ACMD(do_cube) { const char *line; char arg1[256], arg2[256], arg3[256]; line = two_arguments(argument, arg1, sizeof(arg1), arg2, sizeof(arg2)); one_argument(line, arg3, sizeof(arg3)); if (0 == arg1[0]) { return; } switch (LOWER(arg1[0])) { case 'o': // open Cube_open(ch); break; default: return; } } 14. Otwórz game/input.h i znajdź w nim: void Refine(LPCHARACTER ch, const char* c_pData); Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL void CubeRenewalSend(LPCHARACTER ch, const char* data); #endif 15. Otwórz game/input_main.cpp i znajdź w nim: case HEADER_CG_DRAGON_SOUL_REFINE: { TPacketCGDragonSoulRefine* p = reinterpret_cast <TPacketCGDragonSoulRefine*>((void*)c_pData); switch(p->bSubType) { case DS_SUB_HEADER_CLOSE: ch->DragonSoul_RefineWindow_Close(); break; case DS_SUB_HEADER_DO_REFINE_GRADE: { DSManager::instance().DoRefineGrade(ch, p->ItemGrid); } break; case DS_SUB_HEADER_DO_REFINE_STEP: { DSManager::instance().DoRefineStep(ch, p->ItemGrid); } break; case DS_SUB_HEADER_DO_REFINE_STRENGTH: { DSManager::instance().DoRefineStrength(ch, p->ItemGrid); } break; } } break; Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL case HEADER_CG_CUBE_RENEWAL: CubeRenewalSend(ch, c_pData); break; #endif Na końcu pliku dodaj: #ifdef ENABLE_CUBE_RENEWAL void CInputMain::CubeRenewalSend(LPCHARACTER ch, const char* data) { struct packet_send_cube_renewal * pinfo = (struct packet_send_cube_renewal *) data; switch (pinfo->subheader) { case CUBE_RENEWAL_SUB_HEADER_MAKE_ITEM: { int index_item = pinfo->index_item; int count_item = pinfo->count_item; int index_item_improve = pinfo->index_item_improve; Cube_Make(ch,index_item,count_item,index_item_improve); } break; case CUBE_RENEWAL_SUB_HEADER_CLOSE: { Cube_close(ch); } break; } } #endif 16. Otwórz game/item_manager.cpp i znajdź w nim: #include "cube.h" Dodaj pod: #include "cube_renewal.h" 17. Otwórz game/packet.h i znajdź w nim: HEADER_CG_CLIENT_VERSION = 0xfd, HEADER_CG_CLIENT_VERSION2 = 0xf1, /********************************************************/ HEADER_GC_KEY_AGREEMENT_COMPLETED = 0xfa, // _IMPROVED_PACKET_ENCRYPTION_ HEADER_GC_KEY_AGREEMENT = 0xfb, // _IMPROVED_PACKET_ENCRYPTION_ HEADER_GC_TIME_SYNC = 0xfc, HEADER_GC_PHASE = 0xfd, HEADER_GC_BINDUDP = 0xfe, HEADER_GC_HANDSHAKE = 0xff, Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL HEADER_CG_CUBE_RENEWAL = 215, #endif Znajdź: HEADER_GC_DRAGON_SOUL_REFINE = 209, HEADER_GC_RESPOND_CHANNELSTATUS = 210, Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL HEADER_GC_CUBE_RENEWAL = 217, #endif Znajdź: #pragma pack() #endif Dodaj nad: #ifdef ENABLE_CUBE_RENEWAL enum { CUBE_RENEWAL_SUB_HEADER_OPEN_RECEIVE, CUBE_RENEWAL_SUB_HEADER_CLEAR_DATES_RECEIVE, CUBE_RENEWAL_SUB_HEADER_DATES_RECEIVE, CUBE_RENEWAL_SUB_HEADER_DATES_LOADING, CUBE_RENEWAL_SUB_HEADER_MAKE_ITEM, CUBE_RENEWAL_SUB_HEADER_CLOSE, }; typedef struct packet_send_cube_renewal { BYTE header; BYTE subheader; DWORD index_item; DWORD count_item; DWORD index_item_improve; } TPacketCGCubeRenewalSend; typedef struct dates_cube_renewal { DWORD npc_vnum; DWORD index; DWORD vnum_reward; int count_reward; bool item_reward_stackable; DWORD vnum_material_1; int count_material_1; DWORD vnum_material_2; int count_material_2; DWORD vnum_material_3; int count_material_3; DWORD vnum_material_4; int count_material_4; DWORD vnum_material_5; int count_material_5; int gold; int percent; char category[100]; } TInfoDateCubeRenewal; typedef struct packet_receive_cube_renewal { packet_receive_cube_renewal(): header(HEADER_GC_CUBE_RENEWAL) {} BYTE header; BYTE subheader; TInfoDateCubeRenewal date_cube_renewal; } TPacketGCCubeRenewalReceive; #endif 18. Otwórz game/packet_info.cpp i znajdź w nim: Set(HEADER_CG_STATE_CHECKER, sizeof(BYTE), "ServerStateCheck", false); Dodaj pod: #ifdef ENABLE_CUBE_RENEWAL Set(HEADER_CG_CUBE_RENEWAL, sizeof(TPacketCGCubeRenewalSend), "CubeRenewalSend", true); #endif 19. Dopisz do game/Makefile: cube_renewal.cpp 20. Dodaj do swojego cube.cpp/cube.h #ifndef ENABLE_CUBE_RENEWAL na początku i #endif na końcu. 21. Dodaj do game: cube_renewal.cpp cube_renewal.h 22. Otwórz root/game.py i znajdź w nim: def BINARY_DragonSoulGiveQuilification(self): self.interface.DragonSoulGiveQuilification() Dodaj nad: if app.ENABLE_CUBE_RENEWAL: def BINARY_CUBE_RENEWAL_OPEN(self): if self.interface: self.interface.BINARY_CUBE_RENEWAL_OPEN() 23. Otwórz root/interfaceModule.py i znajdź w nim: self.wndDragonSoulRefine = None self.wndChat = None Dodaj pod: if app.ENABLE_CUBE_RENEWAL: self.wndCubeRenewal = None Znajdź: def __MakeCubeResultWindow(self): self.wndCubeResult = uiCube.CubeResultWindow() self.wndCubeResult.LoadWindow() self.wndCubeResult.Hide() Dodaj pod: if app.ENABLE_CUBE_RENEWAL: def __MakeCubeRenewal(self): import uicuberenewal self.wndCubeRenewal = uicuberenewal.CubeRenewalWindows() self.wndCubeRenewal.Hide() Znajdź: self.__MakeCubeWindow() self.__MakeCubeResultWindow() Dodaj pod: if app.ENABLE_CUBE_RENEWAL: self.__MakeCubeRenewal() Znajdź: # ACCESSORY_REFINE_ADD_METIN_STONE if self.wndItemSelect: self.wndItemSelect.Destroy() # END_OF_ACCESSORY_REFINE_ADD_METIN_STONE Dodaj pod: if app.ENABLE_CUBE_RENEWAL: if self.wndCubeRenewal: self.wndCubeRenewal.Destroy() self.wndCubeRenewal.Close() Znajdź: del self.wndUICurtain del self.wndChat Dodaj pod: if app.ENABLE_CUBE_RENEWAL: del self.wndCubeRenewal Znajdź: def SucceedCubeWork(self, itemVnum, count): self.wndCube.Clear() print "큐브 제작 성공! [%d:%d]" % (itemVnum, count) if 0: # 결과 메시지 출력은 생략 한다 self.wndCubeResult.SetPosition(*self.wndCube.GetGlobalPosition()) self.wndCubeResult.SetCubeResultItem(itemVnum, count) self.wndCubeResult.Open() self.wndCubeResult.SetTop() Dodaj pod: if app.ENABLE_CUBE_RENEWAL: def BINARY_CUBE_RENEWAL_OPEN(self): self.wndCubeRenewal.Show() 24. Dodaj do root: uicuberenewal.py 25. Dodaj do uiscript: cuberenewalwindow.py 26. Tłumaczenie locale_interface.txt: CUBE_RENEWAL_TITLE Okienko uszlachetniania CUBE_RENEWAL_BELT_IMPROVE Podwyższ Szansę
  3. Siema dawno temu kupiłem to od Shanga jeśli kiedykolwiek to było lub gdzieś jest juz udostępnione to wywalcie Nie mam screenów system testowany na moich plikach Verti które udostępniłem i działa 1000% [Hidden Content] Skan: Spolszczenie locale_game.txt TICKET_PRIORITY_HIGH Wysoki TICKET_PRIORITY_MEDIUM Średni TICKET_PRIORITY_LOW Niski TICKET_STATE_ON_HOLD W procesie TICKET_STATE_CLOSED Zamknięte TICKET_STATE_SOLVED Rozwiązany TICKET_ADD_NAME Nazwa: TICKET_ADD_TITLE Dodaćj członka TICKET_ADD_ACCEPT Akceptuj TICKET_SEND Wyślij TICKET_TITLE System Zgłoszeń TICKET_MY_TICKETS Moje Zgłoszenia TICKET_ADMINISTRATION Administrator TICKET_SORT_BY Sortuj według: TICKET_ID ID TICKET_TITLE_T Tytuł TICKET_PRIORITY Priorytet TICKET_DATE Data TICKET_STATE Stan TICKET_CREATE_NEW Utwórz nowe zgłoszenie TICKET_SEARCH Szukaj ID: TICKET_SEARCH_BUTTON Szukaj TICKET_NAME Nazwa TICKET_ANSWER Odpowiedź TICKET_DELETE Usuń członka TICKET_CHANGE_PERMISIONS Modyfikowania Uprawnień TICKET_ADD_MEMBER Dodaj nowego członka TICKET_REFRESH Odśwież TICKET_CATEGORY Kategorie TICKET_CATEGORY_0 Wszystko Spolszczenie uiticket.txt import ui import grp import chat import constInfo import event import localeInfo import pythonApi player = __import__(pythonApi.GetModuleName("player")) app = __import__(pythonApi.GetModuleName("app")) from _weakref import proxy CATEGORIES = [ localeInfo.TICKET_CATEGORY_0, 'Sugestie', 'Bugi', 'Hacki', 'Inne', ] class TicketWindow(ui.ScriptWindow): def __init__(self): ui.ScriptWindow.__init__(self) self.isLoaded = FALSE def __del__(self): ui.ScriptWindow.__del__(self) def __LoadWindow(self): try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "uiscript/TicketWindow.py") except: import exception exception.Abort("TicketWindow.__LoadWindow.LoadObject") self.pages = ['MY_TICKETS', 'ADMINISTRATOR'] self.priority_levels = [localeInfo.TICKET_PRIORITY_LOW, localeInfo.TICKET_PRIORITY_MEDIUM, localeInfo.TICKET_PRIORITY_HIGH] self.sort = [localeInfo.TICKET_DATE, localeInfo.TICKET_STATE, localeInfo.TICKET_PRIORITY] self.tmpID = '' self.myticketsPos = 0 self.globalticketsPos = 0 self.permisionsPos = 0 self.priority = 0 self.category = 0 self.curPage = self.pages[0] self.curCategory = 0 self.lastSort = 0 self.isGM = FALSE self.lastSaw = '' self.sortedList = [] self.isSorting = FALSE self.__BindObjects() self.__BindEvents() self.isLoaded = TRUE def __BindObjects(self): self.board = self.GetChild('board') for i in xrange(2): self.GetChild('btnpage%d' % (i+1)).SetEvent(ui.__mem_func__(self.SelectPage), self.pages[i]) self.elements = { 'listboxes' : {'my_tickets' : self.GetChild('my_tickets_listbox'), 'admin' : self.GetChild('admin_listbox')}, 'scrollbars' : {'my_tickets' : self.GetChild('my_tickets_scrollbar'), 'admin' : self.GetChild('admin_scrollbar'), 'permisions' : self.GetChild('permisions_scrollbar')}, 'editlines' : {'create_ticket' : {'title' : self.GetChild('create_ticket_title_value'), 'msg' : self.GetChild('create_ticket_msg')}, 'search' : self.GetChild('search_value')}, 'comboboxes' : {'create_ticket' : 0, 'sort' : 0}, 'buttons' : {'create_ticket' : 0, 'add_member' : self.GetChild('permisions_add_member'), 'search' : self.GetChild('search_button')}, 'priorities' : {}, 'unique_ticket' : TicketManage(), 'add_member' : AddMember(), } for i in xrange(7): self.elements.update({'permision_%d' % i: PermisionManage()}) self.elements['comboboxes']['create_ticket'] = ui.ComboBox() self.elements['comboboxes']['create_ticket'].SetParent(self.GetChild('create_ticket_bg')) self.elements['comboboxes']['create_ticket'].SetSize(55, 15) self.elements['comboboxes']['create_ticket'].SetPosition(78, 46) self.elements['comboboxes']['create_ticket'].SetWindowHorizontalAlignRight() self.elements['comboboxes']['create_ticket'].SetEvent(self.SelectPriority) self.elements['comboboxes']['create_ticket'].Show() self.elements['comboboxes']['create_ticket_category'] = ui.ComboBox() self.elements['comboboxes']['create_ticket_category'].SetParent(self.GetChild('create_ticket_bg')) self.elements['comboboxes']['create_ticket_category'].SetSize(90, 15) self.elements['comboboxes']['create_ticket_category'].SetPosition(245, 46) self.elements['comboboxes']['create_ticket_category'].SetWindowHorizontalAlignRight() self.elements['comboboxes']['create_ticket_category'].SetEvent(self.SelectCategorySend) self.elements['comboboxes']['create_ticket_category'].Show() self.elements['comboboxes']['sort'] = ui.ComboBox() self.elements['comboboxes']['sort'].SetParent(self.GetChild('board')) self.elements['comboboxes']['sort'].SetSize(65, 18) self.elements['comboboxes']['sort'].SetPosition(34+55, 35) self.elements['comboboxes']['sort'].SetWindowHorizontalAlignRight() self.elements['comboboxes']['sort'].SetEvent(self.SelectSort) self.elements['comboboxes']['sort'].Show() self.elements['comboboxes']['categories'] = ui.ComboBox() self.elements['comboboxes']['categories'].SetParent(self.GetChild('board')) self.elements['comboboxes']['categories'].SetSize(100, 18) self.elements['comboboxes']['categories'].SetPosition(180+68+14, 35) self.elements['comboboxes']['categories'].SetWindowHorizontalAlignRight() self.elements['comboboxes']['categories'].SetEvent(self.SelectCategory) self.elements['comboboxes']['categories'].Show() self.elements['buttons']['create_ticket'] = ui.CoolButton() self.elements['buttons']['create_ticket'].SetParent(self.GetChild('create_ticket_bg_msg2')) self.elements['buttons']['create_ticket'].SetSize(95, 50) self.elements['buttons']['create_ticket'].SetPosition(102, 0) self.elements['buttons']['create_ticket'].SetWindowHorizontalAlignRight() self.elements['buttons']['create_ticket'].SetWindowVerticalAlignCenter() self.elements['buttons']['create_ticket'].SetEvent(ui.__mem_func__(self.SendTicket)) self.elements['buttons']['create_ticket'].SetText(localeInfo.TICKET_SEND) self.elements['buttons']['create_ticket'].Show() idx = 0 for prty in self.priority_levels: self.elements['comboboxes']['create_ticket'].InsertItem(idx, prty) idx += 1 idx = 0 for obj in self.sort: self.elements['comboboxes']['sort'].InsertItem(idx, obj) idx += 1 idx = 0 for cat in CATEGORIES: self.elements['comboboxes']['categories'].InsertItem(idx, cat) idx += 1 for i in xrange(len(CATEGORIES)-1): self.elements['comboboxes']['create_ticket_category'].InsertItem(i, CATEGORIES[i+1]) def __BindEvents(self): self.board.SetCloseEvent(ui.__mem_func__(self.Close)) self.elements['comboboxes']['create_ticket'].SelectItem(0) self.elements['comboboxes']['create_ticket_category'].SelectItem(0) self.elements['editlines']['create_ticket']['title'].SetReturnEvent(ui.__mem_func__(self.elements['editlines']['create_ticket']['msg'].SetFocus)) self.elements['editlines']['create_ticket']['title'].SetTabEvent(ui.__mem_func__(self.elements['editlines']['create_ticket']['msg'].SetFocus)) self.elements['editlines']['create_ticket']['msg'].SetTabEvent(ui.__mem_func__(self.elements['editlines']['create_ticket']['title'].SetFocus)) self.elements['editlines']['create_ticket']['title'].SetEscapeEvent(ui.__mem_func__(self.Close)) self.elements['editlines']['create_ticket']['msg'].SetEscapeEvent(ui.__mem_func__(self.Close)) self.elements['editlines']['search'].SetEscapeEvent(ui.__mem_func__(self.Close)) self.elements['unique_ticket'].Open(self.GetChild('window3'), 1, 5) self.elements['unique_ticket'].SetCloseEvent(self.Close) self.elements['listboxes']['my_tickets'].SetSelectEvent(self.SelectMyTicket) self.elements['scrollbars']['my_tickets'].SetScrollEvent(self.__OnScrollMyTickets) self.elements['listboxes']['admin'].SetSelectEvent(self.SelectGlobalTicket) self.elements['scrollbars']['admin'].SetScrollEvent(self.__OnScrollGlobalTickets) self.elements['scrollbars']['permisions'].SetScrollEvent(self.__OnScrollPermisions) for i in xrange(7): self.elements['permision_%d' % i].Open(self.GetChild('permisions_bg'), 0, 10+20*i) self.elements['permision_%d' % i].SetWindowHorizontalAlignCenter() self.elements['buttons']['add_member'].SetEvent(ui.__mem_func__(self.__OnClickAddMember)) self.elements['add_member'].Open(self.board, 0, -20) self.elements['add_member'].SetWindowHorizontalAlignCenter() self.elements['add_member'].SetWindowVerticalAlignCenter() self.elements['add_member'].Hide() self.elements['buttons']['search'].SetEvent(ui.__mem_func__(self.SelectFoundTicket)) self.elements['comboboxes']['sort'].SelectItem(0) def Close(self): constInfo.Tickets['QCMD'] = 'CLOSE#' event.QuestButtonClick(constInfo.Tickets['QID']) self.Hide() def Destroy(self): self.Close() self.ClearDictionary() def OnPressEscapeKey(self): self.Close() return TRUE def RequestOpen(self): constInfo.Tickets['QCMD'] = 'OPEN#' event.QuestButtonClick(constInfo.Tickets['QID']) def Open(self, mode): if not self.isLoaded: self.__LoadWindow() if mode == 1: self.SetGmMode() else: self.SetPlayerMode() self.RefreshMode() self.SelectPage('MY_TICKETS') self.SetCenterPosition() self.SetTop() self.Show() def SetPlayerMode(self): self.isGM = FALSE self.GetChild('btnpage2').Hide() def SetGmMode(self): self.isGM = TRUE self.GetChild('btnpage2').Show() def RefreshMode(self): if self.IsMember(): self.SetGmMode() else: self.SetPlayerMode() self.elements['unique_ticket'].SetGMLevel(self.isGM) def IsMember(self): for i in xrange(len(constInfo.Tickets['PERMISIONS'])): if constInfo.Tickets['PERMISIONS'][i][0] == player.GetName(): return TRUE return FALSE def SelectPage(self, pageName): for i in xrange(2): self.GetChild('btnpage%d' % (i+1)).SetUp() for i in xrange(3): self.GetChild('window%d' % (i+1)).Hide() self.curPage = pageName self.elements['add_member'].Hide() self.isSorting = FALSE idx = 1 if pageName == 'MY_TICKETS': self.myticketsPos = 0 self.SelectSort(0) self.elements['comboboxes']['sort'].SelectItem(self.lastSort) self.RefreshMyTickets() self.ResetTicket() self.elements['comboboxes']['categories'].Hide() idx = 1 elif pageName == 'ADMINISTRATOR': self.globalticketsPos = 0 self.elements['editlines']['search'].SetText('') self.elements['comboboxes']['categories'].Show() self.elements['comboboxes']['categories'].Enable() self.SelectCategory(self.curCategory) self.RefreshPermisions() idx = 2 elif pageName == 'SHOW_TICKET': idx = 3 self.GetChild('window%d' % idx).Show() return self.GetChild('btnpage%d' % idx).Down() self.GetChild('window%d' % idx).Show() def RefreshPage(self): self.RefreshMode() if self.curPage == 'SHOW_TICKET': self.RefreshSelectedTicket() return if self.curPage == 'ADMINISTRATOR' and not self.isGM: self.SelectPage('MY_TICKETS') return self.SelectPage(self.curPage) def RefreshMyTickets(self): self.elements['listboxes']['my_tickets'].RemoveAllItems() for i in xrange(min(len(constInfo.Tickets['MY_TICKETS']), 11)): if self.isSorting: curTicket = self.sortedList[self.myticketsPos + i] else: curTicket = constInfo.Tickets['MY_TICKETS'][self.myticketsPos + i] self.elements['listboxes']['my_tickets'].AppendItem(TicketInfo(curTicket[0], curTicket[1], curTicket[2], curTicket[3], curTicket[5])) if len(constInfo.Tickets['MY_TICKETS']) <= 11: self.elements['scrollbars']['my_tickets'].Hide() else: self.elements['scrollbars']['my_tickets'].SetMiddleBarSize(float(11)/float(len(constInfo.Tickets['MY_TICKETS']))) self.elements['scrollbars']['my_tickets'].Show() def __OnScrollMyTickets(self): myticketslen = len(constInfo.Tickets['MY_TICKETS']) self.myticketsPos = int(self.elements['scrollbars']['my_tickets'].GetPos() * (myticketslen-11)) self.RefreshMyTickets() def __OnScrollGlobalTickets(self): globalticketslen = len(constInfo.Tickets['GLOBAL_TICKETS']) self.globalticketsPos = int(self.elements['scrollbars']['admin'].GetPos() * (globalticketslen-10)) self.RefreshGlobalTickets() def __OnScrollPermisions(self): permisionslen = len(constInfo.Tickets['PERMISIONS']) self.permisionsPos = int(self.elements['scrollbars']['permisions'].GetPos() * (permisionslen-7)) self.RefreshPermisions() def RefreshGlobalTickets(self): self.elements['listboxes']['admin'].RemoveAllItems() if self.isSorting: TicketList = self.sortedList else: TicketList = self.GetCategoryTickets(self.curCategory) for i in xrange(min(len(TicketList), 10)): curTicket = TicketList[self.globalticketsPos + i] self.elements['listboxes']['admin'].AppendItem(TicketInfo(curTicket[0], curTicket[1], curTicket[2], curTicket[3], curTicket[5])) if len(TicketList) <= 10: self.elements['scrollbars']['admin'].Hide() else: self.elements['scrollbars']['admin'].SetMiddleBarSize(float(10)/float(len(TicketList))) self.elements['scrollbars']['admin'].Show() def RefreshPermisions(self): for i in xrange(7): self.elements['permision_%d' % i].Hide() try: for i in xrange(min(len(constInfo.Tickets['PERMISIONS']), 7)): curPermision = constInfo.Tickets['PERMISIONS'][i + self.permisionsPos] self.elements['permision_%d' % i].SetPermisionName(curPermision[0]) if curPermision[1] == 0: self.elements['permision_%d' % i].AnswerCheckBox.SetCheck(FALSE) else: self.elements['permision_%d' % i].AnswerCheckBox.SetCheck(TRUE) if curPermision[2] == 0: self.elements['permision_%d' % i].DeleteCheckBox.SetCheck(FALSE) else: self.elements['permision_%d' % i].DeleteCheckBox.SetCheck(TRUE) if curPermision[3] == 0: self.elements['permision_%d' % i].AddCheckBox.SetCheck(FALSE) else: self.elements['permision_%d' % i].AddCheckBox.SetCheck(TRUE) if i + self.permisionsPos == 0: self.elements['permision_%d' % i].AddCheckBox.Disable() self.elements['permision_%d' % i].DeleteCheckBox.Disable() self.elements['permision_%d' % i].AnswerCheckBox.Disable() self.elements['permision_%d' % i].Show() except: self.elements['scrollbars']['permisions'].Hide() return if len(constInfo.Tickets['PERMISIONS']) <= 7: self.elements['scrollbars']['permisions'].Hide() else: self.elements['scrollbars']['permisions'].SetMiddleBarSize(float(7)/float(len(constInfo.Tickets['PERMISIONS']))) self.elements['scrollbars']['permisions'].Show() def SelectMyTicket(self, idx): if self.isSorting: curTicket = self.sortedList[self.elements['listboxes']['my_tickets'].GetItemIndex(idx) + self.myticketsPos] else: curTicket = constInfo.Tickets['MY_TICKETS'][self.elements['listboxes']['my_tickets'].GetItemIndex(idx) + self.myticketsPos] self.tmpID = curTicket[0] self.elements['unique_ticket'].SetContent(curTicket[0], curTicket[1], curTicket[2], curTicket[3], curTicket[4], curTicket[5], curTicket[6], curTicket[7]) self.elements['comboboxes']['categories'].Show() self.elements['comboboxes']['categories'].Disable() self.elements['comboboxes']['categories'].SetCurrentItem(CATEGORIES[curTicket[8]]) self.SelectPage('SHOW_TICKET') def SelectGlobalTicket(self, idx): if self.isSorting: curTicket = self.sortedList[self.elements['listboxes']['admin'].GetItemIndex(idx) + self.globalticketsPos] else: curTicket = self.GetCategoryTickets(self.curCategory)[self.elements['listboxes']['admin'].GetItemIndex(idx) + self.globalticketsPos] self.tmpID = curTicket[0] self.elements['unique_ticket'].SetContent(curTicket[0], curTicket[1], curTicket[2], curTicket[3], curTicket[4], curTicket[5], curTicket[6], curTicket[7]) self.SelectPage('SHOW_TICKET') def SelectFoundTicket(self, tid = ''): id = self.elements['editlines']['search'].GetText() if tid == '' else tid selected = -1 for i in xrange(len(constInfo.Tickets['GLOBAL_TICKETS'])): if constInfo.Tickets['GLOBAL_TICKETS'][i][0] == id: selected = i break if selected == -1: chat.AppendChat(chat.CHAT_TYPE_INFO, '[System Zgłoszeń] Nie znaleziono żadnego bilet z identyfikatorem %s.' % id) return curTicket = constInfo.Tickets['GLOBAL_TICKETS'][selected] self.tmpID = curTicket[0] self.elements['unique_ticket'].SetContent(curTicket[0], curTicket[1], curTicket[2], curTicket[3], curTicket[4], curTicket[5], curTicket[6], curTicket[7]) self.elements['comboboxes']['categories'].Show() self.elements['comboboxes']['categories'].Disable() self.elements['comboboxes']['categories'].SetCurrentItem(CATEGORIES[curTicket[8]]) self.SelectPage('SHOW_TICKET') def RefreshSelectedTicket(self): self.SelectFoundTicket(self.tmpID) def SelectPriority(self, priority): self.elements['comboboxes']['create_ticket'].SetCurrentItem(self.priority_levels[priority]) self.priority = priority def SelectCategorySend(self, category): self.elements['comboboxes']['create_ticket_category'].SetCurrentItem(CATEGORIES[category+1]) self.category = category+1 def SendTicket(self): self.elements['editlines']['create_ticket']['title'].KillFocus() self.elements['editlines']['create_ticket']['msg'].KillFocus() title = self.elements['editlines']['create_ticket']['title'].GetText() msg = self.elements['editlines']['create_ticket']['msg'].GetText() priority = self.priority+1 if msg == '' or title == '': chat.AppendChat(chat.CHAT_TYPE_INFO, '[System Zgłoszeń] Musisz wypełnić pola poprawnie.') return constInfo.Tickets['QCMD'] = 'CREATE_TICKET#%s#%s#%d#%d' % (title.replace(' ', '[_]'), msg.replace(' ', '[_]'), priority, self.category) event.QuestButtonClick(constInfo.Tickets['QID']) def ResetTicket(self): self.elements['editlines']['create_ticket']['title'].SetText('') self.elements['editlines']['create_ticket']['msg'].SetText('') self.SelectPriority(0) self.elements['comboboxes']['create_ticket'].SelectItem(0) def __OnClickAddMember(self): self.elements['add_member'].ResetValues() self.elements['add_member'].Show() def SelectSort(self, idx): self.elements['comboboxes']['sort'].SetCurrentItem(self.sort[idx]) self.isSorting = TRUE self.lastSort = idx self.sortedList = [] if self.curPage == 'MY_TICKETS': self.sortedList += constInfo.Tickets['MY_TICKETS'] self.sortedList.sort(key=lambda x: x[(3,5,2)[idx]], reverse=(TRUE,FALSE,TRUE)[idx]) self.RefreshMyTickets() elif self.curPage == 'ADMINISTRATOR': self.sortedList += self.GetCategoryTickets(self.curCategory) self.sortedList.sort(key=lambda x: x[(3,5,2)[idx]], reverse=(TRUE,FALSE,TRUE)[idx]) self.RefreshGlobalTickets() def SelectCategory(self, cat_id): self.elements['comboboxes']['categories'].SetCurrentItem(CATEGORIES[cat_id]) self.curCategory = cat_id self.SelectSort(self.lastSort) self.elements['comboboxes']['sort'].SelectItem(self.lastSort) def GetCategoryTickets(self, category): if category == 0: return constInfo.Tickets['GLOBAL_TICKETS'] else: retList = [] for i in xrange(len(constInfo.Tickets['GLOBAL_TICKETS'])): if constInfo.Tickets['GLOBAL_TICKETS'][i][8] == category: retList.append(constInfo.Tickets['GLOBAL_TICKETS'][i]) return retList class TicketInfo(ui.ListBoxEx.Item): def __init__(self, tID, tTitle, priority, tDate, state): ui.ListBoxEx.Item.__init__(self) self.canLoad = 0 if len(tTitle) > 40: self.textLine = self.__CreateTextLine(tID, tTitle[:37]+"...", priority, tDate, state) else: self.textLine = self.__CreateTextLine(tID, tTitle[:40], priority, tDate, state) def __del__(self): ui.ListBoxEx.Item.__del__(self) def SetSize(self, width, height): ui.ListBoxEx.Item.SetSize(self, 375+55, height) def __CreateTextLine(self, tID, tTitle, priority, tDate, state): textID = ui.TextLine() textID.SetParent(self) textID.SetPosition(-186, 0) textID.SetWindowVerticalAlignCenter() textID.SetVerticalAlignCenter() textID.SetWindowHorizontalAlignCenter() textID.SetHorizontalAlignCenter() textID.SetText(tID) textID.Show() textTitle = ui.TextLine() textTitle.SetParent(self) textTitle.SetPosition(-63, 0) textTitle.SetWindowVerticalAlignCenter() textTitle.SetVerticalAlignCenter() textTitle.SetWindowHorizontalAlignCenter() textTitle.SetHorizontalAlignCenter() textTitle.SetText(tTitle) textTitle.Show() textPriority = ui.TextLine() textPriority.SetParent(self) textPriority.SetPosition(54, 0) textPriority.SetWindowVerticalAlignCenter() textPriority.SetVerticalAlignCenter() textPriority.SetWindowHorizontalAlignCenter() textPriority.SetHorizontalAlignCenter() textPriority.SetText((localeInfo.TICKET_PRIORITY_LOW,localeInfo.TICKET_PRIORITY_MEDIUM,localeInfo.TICKET_PRIORITY_HIGH)[priority-1]) textPriority.SetPackedFontColor((grp.GenerateColor(0.7607, 0.7607, 0.7607, 1.0),0xffD87A00,0xffD80000)[priority-1]) textPriority.Show() textDate = ui.TextLine() textDate.SetParent(self) textDate.SetPosition(124, 0) textDate.SetWindowVerticalAlignCenter() textDate.SetVerticalAlignCenter() textDate.SetWindowHorizontalAlignCenter() textDate.SetHorizontalAlignCenter() textDate.SetText(tDate) textDate.Show() imgState = ui.Button() imgState.SetParent(self) imgState.SetPosition(189, 0) imgState.SetWindowHorizontalAlignCenter() imgState.SetWindowVerticalAlignCenter() imgState.SetUpVisual(app.GetLocalePath()+"/ui/tickets/%s.tga" % ('onhold','closed','solved')[state-1]) imgState.SetOverVisual(app.GetLocalePath()+"/ui/tickets/%s.tga" % ('onhold','closed','solved')[state-1]) imgState.SetDownVisual(app.GetLocalePath()+"/ui/tickets/%s.tga" % ('onhold','closed','solved')[state-1]) imgState.SetToolTipText((localeInfo.TICKET_STATE_ON_HOLD,localeInfo.TICKET_STATE_CLOSED,localeInfo.TICKET_STATE_SOLVED)[state-1]) imgState.Show() return textID, textTitle, textPriority, textDate, imgState class PermisionManage(ui.ScriptWindow): class CheckBox(ui.ImageBox): class MouseReflector(ui.Window): def __init__(self, parent): ui.Window.__init__(self) self.SetParent(parent) self.AddFlag("not_pick") self.width = self.height = 0 self.isDown = FALSE def Down(self): self.isDown = TRUE def Up(self): self.isDown = FALSE def OnRender(self): import grp if self.isDown: grp.SetColor(ui.WHITE_COLOR) else: grp.SetColor(ui.HALF_WHITE_COLOR) x, y = self.GetGlobalPosition() grp.RenderBar(x+2, y+2, self.GetWidth()-4, self.GetHeight()-4) def __init__(self, parent, x, y, event, filename = "d:/ymir work/ui/public/Parameter_Slot_01.sub"): ui.ImageBox.__init__(self) self.SetParent(parent) self.SetPosition(x, y) self.LoadImage(filename) self.mouseReflector = self.MouseReflector(self) self.mouseReflector.SetSize(self.GetWidth(), self.GetHeight()) image = ui.MakeImageBox(self, "d:/ymir work/ui/public/check_image.sub", 0, 0) image.AddFlag("not_pick") image.SetWindowHorizontalAlignCenter() image.SetWindowVerticalAlignCenter() image.Hide() self.Enable = TRUE self.Checked = FALSE self.image = image self.event = event self.Show() self.mouseReflector.UpdateRect() def __del__(self): ui.ImageBox.__del__(self) def SetCheck(self, flag): if flag: self.image.Show() self.Checked = TRUE else: self.image.Hide() self.Checked = FALSE def GetCheck(self): return self.Checked def Disable(self): self.Enable = FALSE def OnMouseOverIn(self): if not self.Enable: return self.mouseReflector.Show() def OnMouseOverOut(self): if not self.Enable: return self.mouseReflector.Hide() def OnMouseLeftButtonDown(self): if not self.Enable: return self.mouseReflector.Down() def OnMouseLeftButtonUp(self): if not self.Enable: return self.mouseReflector.Up() self.event() def __init__(self): ui.ScriptWindow.__init__(self) try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/Ticket_Permision.py") except: import exception exception.Abort("Ticket_Permision.LoadWindow.LoadObject") self.memberName = self.GetChild('name_value') self.deleteMember = self.GetChild('delete_member') event = lambda argSelf=proxy(self), argIndex=0, argPermision='answer': apply(argSelf.OnCheckPriority, (argIndex, argPermision)) self.AnswerCheckBox = self.CheckBox(self, 140, 0, event) event = lambda argSelf=proxy(self), argIndex=1, argPermision='delete': apply(argSelf.OnCheckPriority, (argIndex, argPermision)) self.DeleteCheckBox = self.CheckBox(self, 140+75, 0, event) event = lambda argSelf=proxy(self), argIndex=2, argPermision='add': apply(argSelf.OnCheckPriority, (argIndex, argPermision)) self.AddCheckBox = self.CheckBox(self, 140+75*2, 0, event) self.deleteMember.SetEvent(ui.__mem_func__(self.DeleteMember)) def __del__(self): ui.ScriptWindow.__del__(self) def OnCheckPriority(self, argIndex, argPermision): permision = 0 if argPermision == 'answer': if self.AnswerCheckBox.GetCheck(): self.AnswerCheckBox.SetCheck(FALSE) else: self.AnswerCheckBox.SetCheck(TRUE) permision = 1 elif argPermision == 'delete': if self.DeleteCheckBox.GetCheck(): self.DeleteCheckBox.SetCheck(FALSE) else: self.DeleteCheckBox.SetCheck(TRUE) permision = 1 elif argPermision == 'add': if self.AddCheckBox.GetCheck(): self.AddCheckBox.SetCheck(FALSE) else: self.AddCheckBox.SetCheck(TRUE) permision = 1 constInfo.Tickets['QCMD'] = 'UPDATE_PERMISIONS#%s#%s#%d' % (self.memberName.GetText(), argPermision, permision) event.QuestButtonClick(constInfo.Tickets['QID']) def SetPermisionName(self, name): self.memberName.SetText(name) def DeleteMember(self): name = self.memberName.GetText() if name == '': return constInfo.Tickets['QCMD'] = 'DELETE_MEMBER#%s' % name event.QuestButtonClick(constInfo.Tickets['QID']) def Open(self, parent, x, y): self.SetParent(parent) self.SetPosition(x, y) self.Show() class TicketManage(ui.ScriptWindow): class TicketManageTop(ui.ScriptWindow): def __init__(self): ui.ScriptWindow.__init__(self) try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/Ticket_Manage_Top.py") except: import exception exception.Abort("Ticket_Manage_Top.LoadWindow.LoadObject") self.title = self.GetChild('title_value') self.stateBoard = self.GetChild('state_bar') self.state = self.GetChild('state_value') self.id = self.GetChild('ticket_id_value') self.priority = self.GetChild('ticket_priority_value') self.date = self.GetChild('ticket_date_value') self.answers = self.GetChild('ticket_answers_value') self.stateColours = [grp.GenerateColor(1.0, 0.6, 0.1, 0.4),grp.GenerateColor(1.0, 0.0, 0.0, 0.4),grp.GenerateColor(0.0, 1.0, 0.0, 0.4)] def __del__(self): ui.ScriptWindow.__del__(self) def SetContent(self, id, title, date, priority): self.id.SetText(id) self.title.SetText(title) self.priority.SetText((localeInfo.TICKET_PRIORITY_LOW,localeInfo.TICKET_PRIORITY_MEDIUM,localeInfo.TICKET_PRIORITY_HIGH)[priority-1]) self.date.SetText(date) try: self.answers.SetText('%d' % len(constInfo.Tickets['ANSWERS'][id])) except: self.answers.SetText('0') def SetState(self, state): self.stateBoard.SetColor(self.stateColours[state-1]) self.state.SetText((localeInfo.TICKET_STATE_ON_HOLD,localeInfo.TICKET_STATE_CLOSED,localeInfo.TICKET_STATE_SOLVED)[state-1]) class TicketManageMiddle(ui.ScriptWindow): class Answer(ui.ScriptWindow): def __init__(self): ui.ScriptWindow.__init__(self) try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/Ticket_Manage_Answer.py") except: import exception exception.Abort("Ticket_Manage_Answer.LoadWindow.LoadObject") self.msg = self.GetChild('msg') self.msg.CanEdit(FALSE) def __del__(self): ui.ScriptWindow.__del__(self) def SetContent(self, creator, date, hour, msg): self.GetChild('creator_date_value').SetText('Gracz: %s o godzinie: %s %s' % (creator, date, hour)) self.GetChild('h_line').SetSize(self.GetChild('creator_date_value').GetTextSize()[0]+12, 0) self.msg.SetText(msg) def __init__(self): ui.ScriptWindow.__init__(self) self.id = '' self.ticketsPos = 0 try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/Ticket_Manage_Middle.py") except: import exception exception.Abort("Ticket_Manage_Middle.LoadWindow.LoadObject") self.msg = self.GetChild('msg') self.msg.CanEdit(FALSE) self.scrollbar = self.GetChild('scrollbar') self.scrollbar.SetScrollEvent(self.__OnScroll) self.answers = {'0' : self.Answer(), '1' : self.Answer()} for i in xrange(2): self.answers['%d' % i].SetParent(self) self.answers['%d' % i].SetPosition(-5, 80+78*i) self.answers['%d' % i].SetWindowHorizontalAlignCenter() self.answers['%d' % i].Hide() def __del__(self): ui.ScriptWindow.__del__(self) def SetContent(self, id, creator, date, hour, msg): self.id = id self.GetChild('creator_date_value').SetText('Gracz: %s o godzinie: %s %s' % (creator, date, hour)) self.GetChild('h_line').SetSize(self.GetChild('creator_date_value').GetTextSize()[0]+12, 0) self.msg.SetText(msg) self.ticketsPos = 0 self.RefreshAnswers() def RefreshAnswers(self): for i in xrange(2): self.answers['%d' % i].Hide() try: for i in xrange(2): curTicket = constInfo.Tickets['ANSWERS'][self.id][self.ticketsPos + i] self.answers['%d' % i].SetContent(curTicket[0], curTicket[1], curTicket[2], curTicket[3]) self.answers['%d' % i].Show() except: self.scrollbar.Hide() return if len(constInfo.Tickets['ANSWERS'][self.id]) <= 2: self.scrollbar.Hide() else: self.scrollbar.SetMiddleBarSize(float(2)/float(len(constInfo.Tickets['ANSWERS'][self.id]))) self.scrollbar.Show() def __OnScroll(self): ticketslen = len(constInfo.Tickets['ANSWERS'][self.id]) self.ticketsPos = int(self.scrollbar.GetPos() * (ticketslen-2)) self.RefreshAnswers() class TicketManageBottom(ui.ScriptWindow): def __init__(self): ui.ScriptWindow.__init__(self) self.id = '' self.state = 1 try: pyScrLoader = ui.PythonScriptLoader() pyScrLoader.LoadScriptFile(self, "UIScript/Ticket_Manage_Bottom.py") except: import exception exception.Abort("Ticket_Manage_Bottom.LoadWindow.LoadObject") self.msg = self.GetChild('msg') self.send = self.GetChild('send_button') for i in xrange(3): self.GetChild('state_%d_button' % (i+1)).SetEvent(ui.__mem_func__(self.SetState), (i+1)) self.GetChild('state_%d_button' % (i+1)).Hide() self.send.SetEvent(ui.__mem_func__(self.SendTicket)) def __del__(self): ui.ScriptWindow.__del__(self) def SetContent(self, id, state): self.id = id self.SetState(state) def SetState(self, state): for i in xrange(3): self.GetChild('state_%d_button' % (i+1)).SetUp() self.state = state self.GetChild('state_%d_button' % state).Down() def SetGMAction(self, level): if level: for i in xrange(3): self.GetChild('state_%d_button' % (i+1)).Show() else: for i in xrange(3): self.GetChild('state_%d_button' % (i+1)).Hide() def SendTicket(self): constInfo.Tickets['QCMD'] = 'ANSWER_TICKET#%s#%d#%s' % (self.id, self.state, self.msg.GetText().replace(' ', '[_]')) event.QuestButtonClick(constInfo.Tickets['QID']) self.msg.SetText('') def SetCloseEvent(self, func): self.msg.SetEscapeEvent(func) def __init__(self): ui.Window.__init__(self) self.Top = self.TicketManageTop() self.Top.SetParent(self) self.Top.SetPosition(0, 0) self.Top.Show() self.Middle = self.TicketManageMiddle() self.Middle.SetParent(self) self.Middle.SetPosition(0, self.Top.GetHeight()+1) self.Middle.Show() self.Bottom = self.TicketManageBottom() self.Bottom.SetParent(self) self.Bottom.SetPosition(0, self.Top.GetHeight()+1+self.Middle.GetHeight()+1) self.Bottom.Show() self.SetSize(self.Top.GetWidth(), self.Top.GetHeight()+self.Middle.GetHeight()+self.Bottom.GetHeight()+2) def __del__(self): ui.Window.__del__(self) def SetCloseEvent(self, func): self.Bottom.SetCloseEvent(func) def SetContent(self, id, title, priority, date, hour, state, creator, msg): self.Top.SetContent(id, title, date, priority) self.Top.SetState(state) self.Middle.SetContent(id, creator, date, hour, msg) self.Bottom.SetContent(id, state) def SetGMLevel(self, level): self.Bottom.SetGMAction(level) def Open(self, parent, x, y): self.SetParent(parent) self.SetPosition(x, y) self.SetTop() self.Show() class AddMember(ui.Window): def __init__(self): ui.Window.__init__(self) self.board = ui.BoardWithTitleBar() self.board.SetParent(self) self.board.SetSize(185, 100) self.board.SetPosition(0, 0) self.board.SetTitleName(localeInfo.TICKET_ADD_TITLE) self.board.SetCloseEvent(ui.__mem_func__(self.Hide)) self.board.Show() self.nameSlot = ui.MakeSlotBar(self.board, 23, 40, 100, 18) self.nameSlot.SetWindowHorizontalAlignCenter() self.nameText = ui.TextLine() self.nameText.SetParent(self.nameSlot) self.nameText.SetPosition(105, 3) self.nameText.SetWindowHorizontalAlignRight() self.nameText.SetHorizontalAlignRight() self.nameText.SetText(localeInfo.TICKET_ADD_NAME) self.nameText.Show() self.nameValue = ui.EditLine() self.nameValue.SetParent(self.nameSlot) self.nameValue.SetSize(100, 18) self.nameValue.SetPosition(3, 3) self.nameValue.SetMax(16) self.nameValue.SetEscapeEvent(ui.__mem_func__(self.Hide)) self.nameValue.Show() self.acceptButton = ui.MakeButton(self.board, 0, self.board.GetHeight() - 32, '', 'd:/ymir work/ui/public/', 'large_button_01.sub', 'large_button_02.sub', 'large_button_03.sub') self.acceptButton.SetWindowHorizontalAlignCenter() self.acceptButton.SetText(localeInfo.TICKET_ADD_ACCEPT) self.acceptButton.SetEvent(ui.__mem_func__(self.SendMember)) self.SetSize(185, 100) def __del__(self): ui.Window.__del__(self) def ResetValues(self): self.nameValue.SetText('') self.nameValue.SetFocus() def SendMember(self): self.nameValue.KillFocus() name = self.nameValue.GetText() if name == '': return constInfo.Tickets['QCMD'] = 'ADD_MEMBER#%s' % name event.QuestButtonClick(constInfo.Tickets['QID']) self.Hide() def Open(self, parent, x, y): self.SetParent(parent) self.SetPosition(x, y) self.Show() # Shang ~ Ticketsystem spolszczenie ticket_manage_bottom.txt import grp import pythonApi app = __import__(pythonApi.GetModuleName("app")) BOARD_WIDTH = 448 BOARD_HEIGHT = 102 TICKET_PATH = app.GetLocalePath() + "/ui/tickets/" window = { "name" : "TicketManageMiddle", "x" : 0, "y" : 0, "width" : BOARD_WIDTH, "height" : BOARD_HEIGHT, "children" : ( { "name" : "board", "type" : "bar", "x" : 0, "y" : 0, "width" : BOARD_WIDTH, "height" : BOARD_HEIGHT, "color" : grp.GenerateColor(0.0, 0.0, 0.0, 0.6), "children" : ( { "name" : "msg_bar", "type" : "bar", "horizontal_align" : "center", "x" : 0, "y" : 5, "width" : BOARD_WIDTH - 10, "height" : BOARD_HEIGHT - 32, "color" : grp.GenerateColor(0.0, 0.0, 0.0, 1.0), "children" : ( { "name" : "msg", "type" : "editline", "x" : 3, "y" : 3, "width" : BOARD_WIDTH - 10, "height" : BOARD_HEIGHT - 6, "input_limit" : 300, "multi_line" : 1, "limit_width" : BOARD_WIDTH - 10, }, ), }, { "name" : "send_button", "type" : "button", "x" : BOARD_WIDTH - 95, "y" : BOARD_HEIGHT - 24, "text" : "Odpowiedź ", "default_image" : "d:/ymir work/ui/public/large_button_01.sub", "over_image" : "d:/ymir work/ui/public/large_button_02.sub", "down_image" : "d:/ymir work/ui/public/large_button_03.sub", }, { "name" : "state_1_button", "type" : "radio_button", "x" : 5, "y" : BOARD_HEIGHT - 22, "default_image" : TICKET_PATH + "icon_exp_empty.tga", "over_image" : TICKET_PATH + "icon_exp_full.tga", "down_image" : TICKET_PATH + "icon_exp_full.tga", "children" : ( { "name" : "state_1_text", "type" : "text", "x" : 20, "y" : 2, "text" : "W procesie", }, ), }, { "name" : "state_2_button", "type" : "radio_button", "x" : 85, "y" : BOARD_HEIGHT - 22, "default_image" : TICKET_PATH + "icon_exp_empty.tga", "over_image" : TICKET_PATH + "icon_exp_full.tga", "down_image" : TICKET_PATH + "icon_exp_full.tga", "children" : ( { "name" : "state_2_text", "type" : "text", "x" : 20, "y" : 2, "text" : "Zamknięty", }, ), }, { "name" : "state_3_button", "type" : "radio_button", "x" : 85+66, "y" : BOARD_HEIGHT - 22, "default_image" : TICKET_PATH + "icon_exp_empty.tga", "over_image" : TICKET_PATH + "icon_exp_full.tga", "down_image" : TICKET_PATH + "icon_exp_full.tga", "children" : ( { "name" : "state_3_text", "type" : "text", "x" : 20, "y" : 2, "text" : "Rozwiązany", }, ), }, ), }, ), } Spolszczenie TICKET_CONFIG PLAYER_DB_TABLE: player.player TICKETS_DB_TABLE: account.tickets ANSWERS_DB_TABLE: account.tickets_answers PERMISIONS_DB_TABLE: account.tickets_permisions MAIN_MEMBER: 7857 TXT_CANNOT_CHANGE_STATE_NOGM: Nie można zmienić status biletu, jeśli nie jesteś GM. TXT_NO_ANSWER_PERMISION: Nie masz wystarczających uprawnień, aby odebrać bilety. TXT_SUCCESSFUL_ANSWERED: Odpowiedź wysłana poprawnie. TXT_SUCCESSFUL_TICKET: Masz poprawnie wysłany bilet. TXT_CANNOT_SET_PERMISION_NAME: Nie ma znaków o tej nazwie. TXT_CANNOT_CREATE_TICKET: Błąd podczas tworzenia biletu. Spróbuj ponownie później. TXT_NO_PERMISIONS: Nie masz uprawnień do tego. TXT_SUCCESSFUL_MEMBER_ADDED: Użytkownik %s pomyślnie dodany. TXT_SUCCESSFUL_MEMBER_DELETED: Użytkownik %s pomyślnie usunięty. TXT_CANNOT_ANSWER_STATE: Nie można odebrać bilet, jeśli jest on zamknięty lub rozwiązane. to chyba tyle ze spolszczen plików jakby coś brakowało pisać
  4. [Hidden Content] // 1. PythonPlayerInput.cpp // 1.0. Search: void CPythonPlayer::PickCloseItem() { ... } // 1.0. Add after: void CPythonPlayer::PickCloseItemVector() { CInstanceBase * pkInstMain = NEW_GetMainActorPtr(); if (!pkInstMain) return; TPixelPosition kPPosMain; pkInstMain->NEW_GetPixelPosition(&kPPosMain); std::vector<DWORD> itemVidList; CPythonItem& rkItem=CPythonItem::Instance(); if (!rkItem.GetCloseItemVector(pkInstMain->GetNameString(), kPPosMain, itemVidList)) return; if(itemVidList.empty()) return; for(int i = 0; i < itemVidList.size(); i++) SendClickItemPacket(itemVidList[i]); } // 2. PythonItem.cpp // 2.0. Search: bool CPythonItem::GetCloseItem (const std::string& myName, const TPixelPosition& c_rPixelPosition, DWORD* pdwItemID, DWORD dwDistance) { .... } // 2.0. Add after: bool CPythonItem::GetCloseItemVector(const std::string& myName, const TPixelPosition& c_rPixelPosition, std::vector<DWORD>& itemVidList) { DWORD dwCloseItemDistance = 1000 * 1000; TGroundItemInstanceMap::iterator i; for (i = m_GroundItemInstanceMap.begin(); i != m_GroundItemInstanceMap.end(); ++i) { TGroundItemInstance * pInstance = i->second; DWORD dwxDistance = DWORD(c_rPixelPosition.x - pInstance->v3EndPosition.x); DWORD dwyDistance = DWORD(c_rPixelPosition.y - (-pInstance->v3EndPosition.y)); DWORD dwDistance = DWORD(dwxDistance * dwxDistance + dwyDistance * dwyDistance); if (dwDistance < dwCloseItemDistance && (pInstance->stOwnership == "" || pInstance->stOwnership == myName)) { itemVidList.push_back(i->first); } } return true; } // 3. PythonItem.h // 3.0. Search: bool GetCloseMoney(const TPixelPosition & c_rPixelPosition, DWORD* dwItemID, DWORD dwDistance=300); // 3.0. Adauga sub: bool GetCloseItemVector(const std::string& myName, const TPixelPosition& c_rPixelPosition, std::vector<DWORD>& itemVidList); // 4. PythonPlayer.cpp // 4.0. Search and replace: void CPythonPlayer::SendClickItemPacket(DWORD dwIID) { if (IsObserverMode()) return; const char * c_szOwnerName; if (!CPythonItem::Instance().GetOwnership(dwIID, &c_szOwnerName)) return; if (strlen(c_szOwnerName) > 0) if (0 != strcmp(c_szOwnerName, GetName())) { CItemData * pItemData; if (!CItemManager::Instance().GetItemDataPointer(CPythonItem::Instance().GetVirtualNumberOfGroundItem(dwIID), &pItemData)) { Tracenf("CPythonPlayer::SendClickItemPacket(dwIID=%d) : Non-exist item.", dwIID); return; } if (!IsPartyMemberByName(c_szOwnerName) || pItemData->IsAntiFlag(CItemData::ITEM_ANTIFLAG_DROP | CItemData::ITEM_ANTIFLAG_GIVE)) { PyCallClassMemberFunc(m_ppyGameWindow, "OnCannotPickItem", Py_BuildValue("()")); return; } } CPythonNetworkStream& rkNetStream=CPythonNetworkStream::Instance(); rkNetStream.SendItemPickUpPacket(dwIID); } // 5. PythonPlayerModule.cpp // 5.0. Search: PyObject * playerPickCloseItem(PyObject* poSelf, PyObject* poArgs) { CPythonPlayer::Instance().PickCloseItem(); return Py_BuildNone(); } // 5.0. Add after: PyObject * playerPickCloseItemVector(PyObject* poSelf, PyObject* poArgs) { CPythonPlayer::Instance().PickCloseItemVector(); return Py_BuildNone(); } // 5.1. Search: { "PickCloseItem", playerPickCloseItem, METH_VARARGS }, // 5.1.Add after:: { "PickCloseItemVector", playerPickCloseItemVector, METH_VARARGS }, // 6. PythonPlayer,h // 6.0. Search: void PickCloseItem(); // 6.0. Add after: void PickCloseItemVector(); // 7. game.py // 7. Search: player.PickCloseItem() // 7. Replace with: player.PickCloseItemVector() // You can make option for fast pickup or not. Fix by mozna było podnosic itemki w party: To: if (dwDistance < dwCloseItemDistance && (pInstance->stOwnership == "" || pInstance->stOwnership == myName)) Zmieniamy na: if (dwDistance < dwCloseItemDistance && (pInstance->stOwnership.empty() || pInstance->stOwnership == myName || CPythonPlayer::Instance().IsPartyMemberByName(pInstance->stOwnership.c_str()))) I dodajemy na samej górze: #include "PythonPlayer.h"
  5. Nie testowane. LWT - Buffi System.rar [Hidden Content]
  6. I have added some necessary visual stuff, although some are just visual. The system only has an error with the display of passive skills that does not show them in order, but I have been lazy to correct it, if someone corrects it and likes to share it would be very nice, otherwise everything should work as it should. I don't provide basic support for implementation, If you notice that something is missing you can let me know and I will add it. GIF visual: [Hidden Content] [Hidden Content] [Hidden Content] 9Skills-Conquerors-Yohara-master.zip
  7. Macie tutaj na dobrą niedzielke, bo pale lacura chlać. A dodajcie sobie jakiś cooldown może na to, bo mi sie nie chciało ? Pozdrawiam cieplutko, jebać turasów brudasów. GIF: Wszystko spakowane w paczce, bo macie osobny uiPickItemDialog, uiscript do tego, checkboxa itd, bo kodu generalnie to pare linijek. Może być że czegos zapomniałem w paczce to napiszcie. DL: [Hidden Content] We ktoś skana zrób jak komuś sie chce, w paczce tylko elementy graficzne i pliki cpp, h, py. Czekam aż będzie śmigać po turku i ktoś napisze że to "jego system", tak jak z bonus changerem, oj tak tak byczki jak ktoś będzie widział to możemy sobie potyrać razem beczunie.
  8. Elo elo może komuś się przyda iż jest to bardzo mało kodu a tutaj działanie systemu: [Działa tylko na GM] Download: [Hidden Content] Virustotal: [Hidden Content]
  9. Skoro i tak już wypłynął na Turka, a brudasy mają tendencję upłynniania nam zawartości forum to trzymajcie. Own window and slots Items are placed in a new window_type just for switchbot Items can be moved from slot to slot Right click on Items in switchbot are putting it back to inventory ALT + LMOUSE is pasting the item-string to chat Changer or Yang Easy to configure if Changer-Items or Yang should be used for each change Amount of Changer or Yang configurable easily Able to use more than one vnum as changer Attribute-Table and Selection Server is sending all Attribute-Sets to the client While selection of an attribute the maximum value is already preselected The list of attributes is filtered for the selected item-type. it’s only possible to select attributes you can get Double selection of attributes isn’t possible Inserting value of attribute can’t exceed it’s max value and will be reset to its max value while typing Searchbar for quick search of desired attribute Searching can be directly accepted by pressing Enter-key when result is one attribute Alternative-Attributes Each slot has multiple alternatives configurable Amount of alternatives easily configurable (Enum: SWITCHBOT_ALTERNATIVE_COUNT) UI is auto adapting itself to specified amount in source Notifications Silent – No ChatPackets are send! If the process if finished successfully it’s sending a private message to the player Networking- & Refresh-Optimizations Own UpdateItem-Packet Only containing needed informations (Slot, Vnum, Attributes, Sockets) Directly passed to switchbot window, when it’s open. ChangeAttribute-Methode optimized: CItem.ChangeAttribute was executing “SetAttribute” for each attribute the item contains. That was always sending an UpdatePacket, which results into about 7 refreshes per single change process. If ChangeAttribute is executed now and the item is placed in window_type “SWITCHBOT” the original update packet is blocked/not send. Switchbot is now setting all attributes and sending ONE packet afterwards to refresh/update the item informations. Tooltip is not shrinking/growing while the process because the amount of attributes will always stay the same. (Much smoother behaviour) Speed-Configuration Since the new update packet is much lighter , only sending once per process and it’s checked serverside it can reach much faster speed configurations. The delays between each change-process can be adjusted in a constant value on top of the new switchbot-class in server source. P2P When warping to another core the switchbot informations are transfered to your target core and will always continue changing even when warping. (Logout clears those informations and stops the bot!) C_Sanii_Switchbot (1).rar
  10. Działa na całej mapie, nawet po przelogowaniu. Myślę, że temat może zniknąć z Premium. 38271133_2020-08-1215-20-09.mp4.ad8974676d8457f01cbd17a21177fc30.mp4 Dzikie Psy.7z
  11. Cześć, jakiś czas temu bawiłem się playersettingmodule, troszkę kodu przeniosłem do C++ lecz brakło mi czasu. Publikuje tutaj nie pełny poradnik, takie bardziej nakierowanie co i jak. Miło by było jak by ktoś go dokończył. Zacznijmy od void CPythonNetworkStream::LoadingPhase() odbiera pakiet od serwera i tworzy obiekty w grze. 1.) Pierwsza optymalizacja to warp po stronie C++ zamiast pythona. Interesują nas funkcje bool CPythonNetworkStream::RecvMainCharacter() bool CPythonNetworkStream::RecvMainCharacter2_EMPIRE() bool CPythonNetworkStream::RecvMainCharacter3_BGM() bool CPythonNetworkStream::RecvMainCharacter4_BGM_VOL() dodajemy do nich na końcu Warp(mainChrPacket.lX, mainChrPacket.lY); przykład: Warp(mainChrPacket.lX, mainChrPacket.lY); SendClientVersionPacket(); return true; następnie należy wyszukać w introloading.py (10, ui.__mem_func__(self.__LoadMap)), i się go pozbyć oraz wszystko inne co ma __LoadMap 2.) Optymalizacja playersettingmodule.py bool CPythonNetworkStream::RecvMainCharacter() bool CPythonNetworkStream::RecvMainCharacter2_EMPIRE() bool CPythonNetworkStream::RecvMainCharacter3_BGM() bool CPythonNetworkStream::RecvMainCharacter4_BGM_VOL() Szukamy PyCallClassMemberFunc(m_apoPhaseWnd[PHASE_WINDOW_LOAD], "LoadData", Py_BuildValue("(ii)", MainChrPacket.lX, MainChrPacket.lY)); dodajemy nad nim InitData(); Jest to nowa funkcja którą musicie sobie stworzyć, jej zawartość: bool CPythonNetworkStream::InitData() { CInstanceBase::SetDustGap(250); CInstanceBase::SetHorseDustGap(500); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DUST, "", "d:/ymir work/effect/etc/dust/dust.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_HORSE_DUST, "", "d:/ymir work/effect/etc/dust/running_dust.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_HIT, "", "d:/ymir work/effect/hit/blow_1/blow_1_low.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_HPUP_RED, "", "d:/ymir work/effect/etc/recuperation/drugup_red.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SPUP_BLUE, "", "d:/ymir work/effect/etc/recuperation/drugup_blue.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SPEEDUP_GREEN, "", "d:/ymir work/effect/etc/recuperation/drugup_green.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DXUP_PURPLE, "", "d:/ymir work/effect/etc/recuperation/drugup_purple.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AUTO_HPUP, "", "d:/ymir work/effect/etc/recuperation/autodrugup_red.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AUTO_SPUP, "", "d:/ymir work/effect/etc/recuperation/autodrugup_blue.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_RAMADAN_RING_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item1.mse", true); // PPK 71135 CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_HALLOWEEN_CANDY_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item2.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_HAPPINESS_RING_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item3.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_LOVE_PENDANT_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item4.mse", true); #ifdef ENABLE_ACCE_SYSTEM CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_ACCE_SUCCEDED, "", "d:/ymir work/effect/etc/buff/buff_item6.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_ACCE_EQUIP, "", "d:/ymir work/effect/etc/buff/buff_item7.mse", true); #endif CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_PENETRATE, "Bip01", "d:/ymir work/effect/hit/gwantong.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_FIRECRACKER, "", "d:/ymir work/effect/etc/firecracker/newyear_firecracker.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SPIN_TOP, "", "d:/ymir work/effect/etc/firecracker/paing_i.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SELECT, "", "d:/ymir work/effect/etc/click/click_select.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_TARGET, "", "d:/ymir work/effect/etc/click/click_glow_select.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_STUN, "Bip01 Head", "d:/ymir work/effect/etc/stun/stun.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_CRITICAL, "Bip01 R Hand", "d:/ymir work/effect/hit/critical.mse", true); //CInstanceBase::RegisterEffect(CPythonPlayer::EFFECT_PICK, "", "d:/ymir work/effect/etc/click/click.mse", true); // playermodulesetting.py CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_TARGET, "", "d:/ymir work/effect/affect/damagevalue/target.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_NOT_TARGET, "", "d:/ymir work/effect/affect/damagevalue/nontarget.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_SELFDAMAGE, "", "d:/ymir work/effect/affect/damagevalue/damage.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_SELFDAMAGE2, "", "d:/ymir work/effect/affect/damagevalue/damage_1.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_POISON, "", "d:/ymir work/effect/affect/damagevalue/poison.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_MISS, "", "d:/ymir work/effect/affect/damagevalue/miss.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_DAMAGE_TARGETMISS, "", "d:/ymir work/effect/affect/damagevalue/target_miss.mse", true); // Wydaje mi się że do wyjebania CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_LEVELUP_ON_14_FOR_GERMANY, "", "d:/ymir work/effect/effect/paymessage_warning.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_LEVELUP_UNDER_15_FOR_GERMANY, "", "d:/ymir work/effect/effect/paymessage_decide.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_PERCENT_DAMAGE1, "", "d:/ymir work/effect/hit/percent_damage1.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_PERCENT_DAMAGE2, "", "d:/ymir work/effect/hit/percent_damage2.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_PERCENT_DAMAGE3, "", "d:/ymir work/effect/hit/percent_damage3.mse", true); LoadGameSound(); LoadGameEffect(); return true; } Dodajemy również dwie nowe funkcje które są na dole LoadGameSound(); LoadGameEffect(); void CPythonNetworkStream::LoadGameSound() { CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_DEFAULT, "sound/ui/drop.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_ACCESSORY, "sound/ui/equip_ring_amulet.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_ARMOR, "sound/ui/equip_metal_armor.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_BOW, "sound/ui/equip_bow.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_WEAPON, "sound/ui/equip_metal_weapon.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_POTION, "sound/ui/eat_potion.wav"); CPythonItem::Instance().SetUseSoundFileName(CPythonItem::USESOUND_PORTAL, "sound/ui/potal_scroll.wav"); CPythonItem::Instance().SetDropSoundFileName(CPythonItem::DROPSOUND_DEFAULT, "sound/ui/drop.wav"); CPythonItem::Instance().SetDropSoundFileName(CPythonItem::DROPSOUND_ACCESSORY, "sound/ui/equip_ring_amulet.wav"); CPythonItem::Instance().SetDropSoundFileName(CPythonItem::DROPSOUND_ARMOR, "sound/ui/equip_metal_armor.wav"); CPythonItem::Instance().SetDropSoundFileName(CPythonItem::DROPSOUND_BOW, "sound/ui/equip_bow.wav"); CPythonItem::Instance().SetDropSoundFileName(CPythonItem::DROPSOUND_WEAPON, "sound/ui/equip_metal_weapon.wav"); } void CPythonNetworkStream::LoadGameEffect() { CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SPAWN_APPEAR, "Bip01", "d:/ymir work/effect/etc/appear_die/monster_appear.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SPAWN_DISAPPEAR, "Bip01", "d:/ymir work/effect/etc/appear_die/monster_die.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_FLAME_ATTACK, "equip_right_hand", "d:/ymir work/effect/hit/blow_flame/flame_3_weapon.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_FLAME_HIT, "", "d:/ymir work/effect/hit/blow_flame/flame_3_blow.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_FLAME_ATTACH, "", "d:/ymir work/effect/hit/blow_flame/flame_3_body.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_ELECTRIC_ATTACK, "equip_right", "d:/ymir work/effect/hit/blow_electric/light_1_weapon.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_ELECTRIC_HIT, "", "d:/ymir work/effect/hit/blow_electric/light_1_blow.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_ELECTRIC_ATTACH, "", "d:/ymir work/effect/hit/blow_electric/light_1_body.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_LEVELUP, "", "d:/ymir work/effect/etc/levelup_1/level_up.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_SKILLUP, "", "d:/ymir work/effect/etc/skillup/skillup_1.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMPIRE + 1, "Bip01", "d:/ymir work/effect/etc/empire/empire_A.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMPIRE + 2, "Bip01", "d:/ymir work/effect/etc/empire/empire_B.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMPIRE + 3, "Bip01", "d:/ymir work/effect/etc/empire/empire_C.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_WEAPON + 1, "equip_right_hand", "d:/ymir work/pc/warrior/effect/geom_sword_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_WEAPON + 2, "equip_right_hand", "d:/ymir work/pc/warrior/effect/geom_spear_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 0, "Bip01", "d:/ymir work/effect/gm/gm.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 3, "Bip01", "d:/ymir work/effect/hit/blow_poison/poison_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 4, "", "d:/ymir work/effect/affect/slow.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 5, "Bip01 Head", "d:/ymir work/effect/etc/stun/stun_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 6, "", "d:/ymir work/effect/etc/ready/ready.mse", true); // #CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 8, "", "d:/ymir work/guild/effect/10_construction.mse", true); // #CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 9, "", "d:/ymir work/guild/effect/20_construction.mse", true); // #CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 10, "", "d:/ymir work/guild/effect/20_upgrade.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 16, "", "d:/ymir work/pc/warrior/effect/gyeokgongjang_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 17, "", "d:/ymir work/pc/assassin/effect/gyeonggong_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 19, "Bip01 R Finger2", "d:/ymir work/pc/sura/effect/gwigeom_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 20, "", "d:/ymir work/pc/sura/effect/fear_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 21, "", "d:/ymir work/pc/sura/effect/jumagap_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 22, "", "d:/ymir work/pc/shaman/effect/3hosin_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 23, "", "d:/ymir work/pc/shaman/effect/boho_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 24, "", "d:/ymir work/pc/shaman/effect/10kwaesok_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 25, "", "d:/ymir work/pc/sura/effect/heuksin_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 26, "", "d:/ymir work/pc/sura/effect/muyeong_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 28, "Bip01", "d:/ymir work/effect/hit/blow_flame/flame_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 29, "Bip01 R Hand", "d:/ymir work/pc/shaman/effect/6gicheon_hand.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 30, "Bip01 L Hand", "d:/ymir work/pc/shaman/effect/jeungryeok_hand.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 32, "Bip01 Head", "d:/ymir work/pc/sura/effect/pabeop_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 33, "", "d:/ymir work/pc/warrior/effect/gyeokgongjang_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 35, "", "d:/ymir work/effect/etc/guild_war_flag/flag_red.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 36, "", "d:/ymir work/effect/etc/guild_war_flag/flag_blue.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 37, "", "d:/ymir work/effect/etc/guild_war_flag/flag_yellow.mse", true); #ifdef ENABLE_WOLFMAN_CHARACTER CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 42, "Bip01", "d:/ymir work/effect/hit/blow_poison/bleeding_loop.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 43, "Bip01", "d:/ymir work/effect/hit/blow_flame/flame_loop_w.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + 44, "", "d:/ymir work/pc3/common/effect/gyeokgongjang_loop_w.mse", true); #endif CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 1, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_7.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 2, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_8.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 3, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_9.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 4, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_7_b.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 5, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_8_b.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 6, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_9_b.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 7, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_7_f.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 8, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_8_f.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 9, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_9_f.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 10, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_7_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 11, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_8_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 12, "PART_WEAPON", "D:/ymir work/pc/common/effect/sword/sword_9_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 13, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_7_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 14, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_8_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 15, "PART_WEAPON_LEFT", "D:/ymir work/pc/common/effect/sword/sword_9_s.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 16, "Bip01", "D:/ymir work/pc/common/effect/armor/armor_7.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 17, "Bip01", "D:/ymir work/pc/common/effect/armor/armor_8.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 18, "Bip01", "D:/ymir work/pc/common/effect/armor/armor_9.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 19, "Bip01", "D:/ymir work/pc/common/effect/armor/armor-4-2-1.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 20, "Bip01", "D:/ymir work/pc/common/effect/armor/armor-4-2-2.mse", true); #ifdef ENABLE_LVL115_ARMOR_EFFECT CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 21, "Bip01", "D:/ymir work/pc/common/effect/armor/armor-5-1.mse", true); #endif // ENABLE_LVL115_ARMOR_EFFECT #ifdef ENABLE_ACCE_SYSTEM CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 28, "Bip01", "d:/ymir work/pc/common/effect/armor/acc_01.mse", true); #endif CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 23, "Bip01", "D:/ymir work/pc/common/effect/armor/aze_shining_white.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 24, "Bip01", "D:/ymir work/pc/common/effect/armor/aze_shining_blue.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 25, "Bip01", "D:/ymir work/pc/common/effect/armor/aze_shining_orange.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 26, "Bip01", "D:/ymir work/pc/common/effect/armor/aze_shining_black.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_REFINED + 27, "Bip01", "D:/ymir work/pc/common/effect/armor/aze_shining_violett.mse", true); #ifdef ENABLE_SOUL_SYSTEM CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + CInstanceBase::AFFECT_SOUL_RED, "", "d:/ymir work/effect/etc/soul/soul_red_001.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + CInstanceBase::AFFECT_SOUL_BLUE, "", "d:/ymir work/effect/etc/soul/soul_blue_001.mse", true); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_AFFECT + CInstanceBase::AFFECT_SOUL_MIX, "", "d:/ymir work/effect/etc/soul/soul_mix_001.mse", true); #endif // ENABLE_SOUL_SYSTEM CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 0, "", "d:/ymir work/effect/etc/emoticon/sweat.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(sweat)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 1, "", "d:/ymir work/effect/etc/emoticon/money.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(money)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 2, "", "d:/ymir work/effect/etc/emoticon/happy.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(happy)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 3, "", "d:/ymir work/effect/etc/emoticon/love_s.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(love_s)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 4, "", "d:/ymir work/effect/etc/emoticon/love_l.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(love_l)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 5, "", "d:/ymir work/effect/etc/emoticon/angry.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(angry)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 6, "", "d:/ymir work/effect/etc/emoticon/aha.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(aha)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 7, "", "d:/ymir work/effect/etc/emoticon/gloom.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(gloom)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 8, "", "d:/ymir work/effect/etc/emoticon/sorry.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(sorry)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 9, "", "d:/ymir work/effect/etc/emoticon/!_mix_back.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(!)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 10, "", "d:/ymir work/effect/etc/emoticon/question.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(?)"); CInstanceBase::RegisterEffect(CInstanceBase::EFFECT_EMOTICON + 11, "", "d:/ymir work/effect/etc/emoticon/fish.mse", true); CPythonNetworkStream::Instance().RegisterEmoticonString("(fish)"); } Tutaj brakuje race, ładowanie skilli itp. Brakło mi czasu, jeżeli ktoś ma czas to niech spróbuje i się podzieli. Będę bardzo wdzięczny. 3. Przeniesienie FlyIndex (zapożyczone od kogoś z jakiegoś forum) Szukamy enum EIndexFlyType pod tym dodajemy enum EIndexEffect { FLY_NONE, FLY_EXP, FLY_HP_MEDIUM, FLY_HP_BIG, FLY_SP_SMALL, FLY_SP_MEDIUM, FLY_SP_BIG, FLY_FIREWORK1, FLY_FIREWORK2, FLY_FIREWORK3, FLY_FIREWORK4, FLY_FIREWORK5, FLY_FIREWORK6, FLY_FIREWORK_XMAS, FLY_CHAIN_LIGHTNING, FLY_HP_SMALL, FLY_SKILL_MUYEONG, }; a następnie szukamy void CFlyingManager::CreateIndexedFly(uint32_t dwIndex, CActorInstance * pStartActor, CActorInstance * pEndActor) i pod if (m_kMap_dwIndexFlyData.end() == m_kMap_dwIndexFlyData.find(dwIndex)) { TraceError("CFlyingManager::CreateIndexedFly(dwIndex=%d) - Not registered index", dwIndex); return; } dodajemy switch (dwIndex) { case FLY_EXP: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_yellow_small2.msf"); break; case FLY_HP_MEDIUM: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_red_small.msf"); break; case FLY_HP_BIG: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_red_big.msf"); break; case FLY_SP_SMALL: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_blue_warrior_small.msf"); break; case FLY_SP_MEDIUM: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_blue_small.msf"); break; case FLY_SP_BIG: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_blue_big.msf"); break; case FLY_FIREWORK1: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_1.msf"); break; case FLY_FIREWORK2:RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_2.msf"); break; case FLY_FIREWORK3: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_3.msf"); break; case FLY_FIREWORK4: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_4.msf"); break; case FLY_FIREWORK5: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_5.msf"); break; case FLY_FIREWORK6: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_6.msf"); break; case FLY_FIREWORK_XMAS: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_FIRE_CRACKER, "d:/ymir work/effect/etc/firecracker/firecracker_xmas.msf"); break; case FLY_CHAIN_LIGHTNING: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/pc/shaman/effect/pokroe.msf"); break; case FLY_HP_SMALL: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_NORMAL, "d:/ymir work/effect/etc/gathering/ga_piece_red_smallest.msf"); break; case FLY_SKILL_MUYEONG: RegisterIndexedFlyData(dwIndex, INDEX_FLY_TYPE_AUTO_FIRE, "d:/ymir work/pc/sura/effect/muyeong_fly.msf"); break; default: break; } Teraz przechodzimy do playersettingmodule.py w root i wypierdzielamy kod który jest zduplikowany wyżej. Jeżeli nikt nie podejmie się dokończenia tego to w wolnej chwili po 16 października dokończę poradnik @Edit: Patrzę właśnie na kod, efekty możecie sobie przenieść na switch w funkcji uint32_t CInstanceBase::__AttachEffect(uint32_t eEftType)
  12. Download: [Hidden Content] Skan: [Hidden Content] Brakuje: Funkcji GetLanguage() Crashe: Jak scraschować server? Wpisujemy do wiadomości nick np Cweluch/ query wykonuję się 'Cweluch\' error i wyjebuje channela, jak coś jeszcze znajdę to zedytuje temat, jak ktoś poprawi to wyślijcie fixa albo dajcie post z fixem.
  13. Wraz z przebudową naszej pobieralni, niektóre wstawki przechodzą do działu. Advanced Control Protection [New Version 10.0 - 26/06/2020] Damage Hack; Hack Damage; Fix WallHack Fix SpeedHack Block File .mix, .asi, .m3d, .py, .dll. Change Key Extraction Change Obfuscation Method Python module load block Change root name Block multithread, process, watcher and scanner Change Index name Change Extensions Fix .dll injection; Fix .py injection; Fix Universal Decrypter Folder integrity check Create thread control RMP / WMP Security [KGO]Advanced Control Protection V.10.7z
  14. Zdecydowanie za dobry dla was jestem ? NIE POMAGAM Z SYSTEMEM NA PW, PROSZĘ PISAĆ POD TEMATEM. DL: (link) HP_GaugeBar affects V2.3.rar Skan: (link) [Hidden Content] changelog: v2.3 [25.04.2020] (uitaskbar.py) - removed one not necessary TAB - added missing condition - replaced wrong RecoveryGaugeBar.hide() with good one v2.2 [22.04.2020] - small animation fix after change target (ui.py) - disabled effects on metin stones (PythonCharacterManagerModule.cpp) @ Tatsumaru pozdrawiam
  15. Przeszukując odmęty internetów znalazłem poprawionego(?) Biologa. Nie testowane Wygląda to tak: [Hidden Content] Professional Biolog Full - Reworked.rar [Hidden Content]
  16. Cześć wrzucam system automatów - Działa tak jak na video ~Nie był testowany - Tutorial został wygenerowany z githuba, więc nie wygląda jak we większościach poradników typu - Szukamy frazy A, dodajemy pod B etc. Głównie kierujcie się plusami i minusami 887dd2b55b0cd3e333aab5a5341f602c.mp4 Download: [Hidden Content] Virustotal: [Hidden Content]
  17. It's not like official but works You will need to do costume windows alone in Binary PART_AURA will not be declared go on RaceData.h Find : PART_ACCE add #ifdef ENABLE_COSTUME_AURA PART_AURA #endif Aura_System_Itachi.7z [Hidden Content]
  18. Jak wyglada ten 'blad': A po naprawieniu: BINKA ~Wchodzimy do PythonSlotWindow.h // Szukamy: typedef TSlotList::iterator TSlotListIterator; // Pod dodajemy: typedef struct SStoreCoolDown { float fCoolTime; float fElapsedTime; bool bActive; }; // Szukamy: void SetSlotCoolTime(DWORD dwIndex, float fCoolTime, float fElapsedTime = 0.0f); // Pod dodajemy: void StoreSlotCoolTime(DWORD dwKey, DWORD dwSlotIndex, float fCoolTime, float fElapsedTime = .0f); void RestoreSlotCoolTime(DWORD dwKey); void TransferSlotCoolTime(DWORD dwIndex1, DWORD dwIndex2); // Szukamy: DWORD m_dwToolTipSlotNumber; // Pod dodajemy std::map<DWORD, std::map<DWORD, SStoreCoolDown>> m_CoolDownStore; ~Wchodzimy do PythonSlotWindow.cpp // Szukamy: void CSlotWindow::SetSlotCoolTime(DWORD dwIndex, float fCoolTime, float fElapsedTime) { ... } // Pod Dodajemy: void CSlotWindow::StoreSlotCoolTime(DWORD dwKey, DWORD dwSlotIndex, float fCoolTime, float fElapsedTime) { std::map<DWORD, SStoreCoolDown>::iterator it = m_CoolDownStore[dwKey].find(dwSlotIndex); if (it != m_CoolDownStore[dwKey].end()) { it->second.fCoolTime = fCoolTime; it->second.fElapsedTime = CTimer::Instance().GetCurrentSecond() - fElapsedTime; it->second.bActive = false; } else { SStoreCoolDown m_storeCoolDown; m_storeCoolDown.fCoolTime = fCoolTime; m_storeCoolDown.fElapsedTime = CTimer::Instance().GetCurrentSecond() - fElapsedTime; m_storeCoolDown.bActive = false; m_CoolDownStore[dwKey].insert(std::map<DWORD, SStoreCoolDown>::value_type(dwSlotIndex, m_storeCoolDown)); } } void CSlotWindow::RestoreSlotCoolTime(DWORD dwKey) { for (std::map<DWORD, SStoreCoolDown>::iterator it = m_CoolDownStore[dwKey].begin(); it != m_CoolDownStore[dwKey].end(); it++) { TSlot * pSlot; if (!GetSlotPointer(it->first, &pSlot)) return; pSlot->fCoolTime = it->second.fCoolTime; pSlot->fStartCoolTime = it->second.fElapsedTime; if (it->second.bActive) ActivateSlot(it->first); else DeactivateSlot(it->first); } } void CSlotWindow::TransferSlotCoolTime(DWORD dwIndex1, DWORD dwIndex2) { std::map<DWORD, SStoreCoolDown>::iterator it = m_CoolDownStore[CPythonSkill::SKILL_TYPE_ACTIVE].find(dwIndex1); if (it != m_CoolDownStore[CPythonSkill::SKILL_TYPE_ACTIVE].end()) { TSlot* pSlot1; if (!GetSlotPointer(dwIndex1, &pSlot1)) return; TSlot* pSlot2; if (!GetSlotPointer(dwIndex2, &pSlot2)) return; // Replacing the cooldown from slot 1 to slot 2 and removing the slot 1 from the map. SStoreCoolDown slotCooldown = it->second; m_CoolDownStore[CPythonSkill::SKILL_TYPE_ACTIVE][dwIndex2] = slotCooldown; m_CoolDownStore[CPythonSkill::SKILL_TYPE_ACTIVE].erase(dwIndex1); // Removing the cooldown from the slot 1. pSlot1->fCoolTime = 0; pSlot1->fStartCoolTime = 0; // Setting the cooldown from slot 1 to slot 2. pSlot2->fCoolTime = slotCooldown.fCoolTime; pSlot2->fStartCoolTime = slotCooldown.fElapsedTime; } } // Szukamy: __CreateSlotEnableEffect(); } // Pod Dodajemy: std::map<DWORD, SStoreCoolDown>::iterator it = m_CoolDownStore[1].find(dwIndex); if (it != m_CoolDownStore[1].end()) it->second.bActive = true; // Szukamy: void CSlotWindow::DeactivateSlot(DWORD dwIndex) { TSlot * pSlot; if (!GetSlotPointer(dwIndex, &pSlot)) return; pSlot->bActive = FALSE; // Pod Dodajemy: std::map<DWORD, SStoreCoolDown>::iterator it = m_CoolDownStore[1].find(dwIndex); if (it != m_CoolDownStore[1].end()) it->second.bActive = false; // Szukamy W void CSlotWindow::__Initialize(): m_dwToolTipSlotNumber = SLOT_NUMBER_NONE; // Pod dodajemy: m_CoolDownStore.clear(); ~Wchodzimy do PythonWindowManagerModule.cpp // Szukamy: PyObject * wndMgrSetSlotCoolTime(PyObject * poSelf, PyObject * poArgs) { ... } // Pod dodajemy: PyObject * wndMgrStoreSlotCoolTime(PyObject * poSelf, PyObject * poArgs) { UI::CWindow * pWin; if (!PyTuple_GetWindow(poArgs, 0, &pWin)) return Py_BuildException(); int iKey; if (!PyTuple_GetInteger(poArgs, 1, &iKey)) return Py_BuildException(); int iSlotIndex; if (!PyTuple_GetInteger(poArgs, 2, &iSlotIndex)) return Py_BuildException(); float fCoolTime; if (!PyTuple_GetFloat(poArgs, 3, &fCoolTime)) return Py_BuildException(); float fElapsedTime = 0.0f; PyTuple_GetFloat(poArgs, 4, &fElapsedTime); if (!pWin->IsType(UI::CSlotWindow::Type())) return Py_BuildException(); UI::CSlotWindow * pSlotWin = (UI::CSlotWindow *)pWin; pSlotWin->StoreSlotCoolTime(iKey, iSlotIndex, fCoolTime, fElapsedTime); return Py_BuildNone(); } PyObject * wndMgrRestoreSlotCoolTime(PyObject * poSelf, PyObject * poArgs) { UI::CWindow * pWin; if (!PyTuple_GetWindow(poArgs, 0, &pWin)) return Py_BuildException(); int iKey; if (!PyTuple_GetInteger(poArgs, 1, &iKey)) return Py_BuildException(); if (!pWin->IsType(UI::CSlotWindow::Type())) return Py_BuildException(); UI::CSlotWindow * pSlotWin = (UI::CSlotWindow *)pWin; pSlotWin->RestoreSlotCoolTime(iKey); return Py_BuildNone(); } PyObject* wndMgrTransferSlotCoolTime(PyObject* poSelf, PyObject* poArgs) { UI::CWindow* pWin; if (!PyTuple_GetWindow(poArgs, 0, &pWin)) return Py_BuildException(); int iIndex1; if (!PyTuple_GetInteger(poArgs, 1, &iIndex1)) return Py_BuildException(); int iIndex2; if (!PyTuple_GetInteger(poArgs, 2, &iIndex2)) return Py_BuildException(); if (!pWin->IsType(UI::CSlotWindow::Type())) return Py_BuildException(); UI::CSlotWindow* pSlotWin = (UI::CSlotWindow*)pWin; pSlotWin->TransferSlotCoolTime(iIndex1, iIndex2); return Py_BuildNone(); } // Szukamy: { "SetSlotCoolTime", wndMgrSetSlotCoolTime, METH_VARARGS }, // Pod dodajemy: { "StoreSlotCoolTime", wndMgrStoreSlotCoolTime, METH_VARARGS }, { "RestoreSlotCoolTime", wndMgrRestoreSlotCoolTime, METH_VARARGS }, { "TransferSlotCoolTime", wndMgrTransferSlotCoolTime, METH_VARARGS }, CLIENT ~Wchodzimy do root/ui.py ## Szukamy: def SetSlotCoolTime(self, slotIndex, coolTime, elapsedTime = 0.0): wndMgr.SetSlotCoolTime(self.hWnd, slotIndex, coolTime, elapsedTime) ## Nie Znalazłeś? ## Szukamy: def SetSlotCoolTime(self, slotIndex, coolTime, elapsedTime = 0.0): wndMgr.SetSlotCoolTime(self.hWnd, slotIndex, coolTime, elapsedTime) ## Pod dodajemy: def StoreSlotCoolTime(self, key, slotIndex, coolTime, elapsedTime = 0.0): wndMgr.StoreSlotCoolTime(self.hWnd, key, slotIndex, coolTime, elapsedTime) def RestoreSlotCoolTime(self, key): wndMgr.RestoreSlotCoolTime(self.hWnd, key) def TransferSlotCoolTime(self, slotIndex1, slotIndex2): wndMgr.TransferSlotCoolTime(self.hWnd, slotIndex1, slotIndex2) ~Wchodzimy do root/uicharacter.py ## Szukamy: skillPage.RefreshSlot() ## Pod dodajemy: self.__RestoreSlotCoolTime(skillPage) ## Szukamy: def RefreshSkill(self): if self.isLoaded==0: return ... ## Nad Dodajemy: def __RestoreSlotCoolTime(self, skillPage): restoreType = skill.SKILL_TYPE_NONE if self.PAGE_HORSE == self.curSelectedSkillGroup: restoreType = skill.SKILL_TYPE_HORSE else: restoreType = skill.SKILL_TYPE_ACTIVE skillPage.RestoreSlotCoolTime(restoreType) ## Szukamy: slotWindow.SetSlotCoolTime(slotIndex, coolTime) ## Zmieniamy na: slotWindow.StoreSlotCoolTime(skillType, slotIndex, coolTime) self.__RestoreSlotCoolTime(slotWindow) ## Szukamy: elif skill.SKILL_TYPE_ACTIVE == skillType: ## Całego elifa podmieniamy na: elif skill.SKILL_TYPE_ACTIVE == skillType: for j in xrange(skill.SKILL_GRADE_COUNT): realSlotIndex = self.__GetRealSkillSlot(j, slotIndex) skillPage.SetSkillSlotNew(realSlotIndex, skillIndex, j, skillLevel) skillPage.SetCoverButton(realSlotIndex) if (skillGrade == skill.SKILL_GRADE_COUNT) and j == (skill.SKILL_GRADE_COUNT-1): skillPage.SetSlotCountNew(realSlotIndex, skillGrade, skillLevel) elif (not self.__CanUseSkillNow()) or (skillGrade != j): skillPage.SetSlotCount(realSlotIndex, 0) skillPage.DisableCoverButton(realSlotIndex) skillPage.DeactivateSlot(realSlotIndex) else: skillPage.SetSlotCountNew(realSlotIndex, skillGrade, skillLevel) if player.IsSkillActive(slotIndex) and (skillGrade == j or (skillGrade >= skill.SKILL_GRADE_COUNT) and j == (skill.SKILL_GRADE_COUNT - 1)): skillPage.ActivateSlot(realSlotIndex) if player.IsSkillCoolTime(slotIndex) and skillGrade != j: skillPage.TransferSlotCoolTime(realSlotIndex, self.__GetRealSkillSlot(skillGrade, i)) Credits: @Shang Mały fix odemnie na: 8cc03926b7dc04ceb3d8d0cc48ca39dc.mp4 ~Wchodzimy do root/uitaskbar.py ## Szukamy: slotNumber = i+startNumber ## Pod dodajemy: slot.DeactivateSlot(slotNumber) Credits: @Jxxkub
  19. Ox Event Manager & Top 5 winners System Vegas'a
  20. Pewnie ma bugi, a wrzucam na prośbę. Download: ITEMSHOP_INGAME.7z Pass: M2Zone.tech
  21. Łapcie cały tutorial dot. Multilanga Podgląd: Download: [Hidden Content] Virustotal: [Hidden Content]
×
×
  • Create New...