Jump to content

Search the Community

Showing results for tags 'pkodev.mod.loader'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Russian Section
    • Новости и объявления
    • Пиратия: Документация
    • Пиратия: Релизы
    • Пиратия: Разработка
    • Пиратия: Web
    • Пиратия: Помощь
    • Совместные проекты / набор команды
    • Доска объявлений
    • Программирование
    • Оффтопик
    • Корзина
  • English Section
    • News & Announcements
    • Guides
    • Releases
    • Development
    • Web
    • Questions & Help
    • Shared Projects / Team search
    • Paid services & Requests
    • Programming
    • Offtopic
    • Recycle bin
  • Portuguese Section
    • Dúvidas & Ajuda
  • Spanish Section
    • Preguntas y Ayuda
  • Servers
    • Russian servers
    • English servers

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Found 62 results

  1. [Mod] System of daily rewards for entering the game This mod implements a system of daily rewards for entering the game. Players need to enter the game every day in order to receive the next reward - with each new day the reward becomes more valuable. The chain resets and starts over from the first day if a player misses a day. The chain is also reset every week. The chain of rewards is configured by the administrator in a special lua function and is generated for a week forward, after which it is saved in the server database. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.reward; Version: 1.0; Author: V3ct0r; Type: for client and server (Game.exe and GameServer.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5, GAMESERVER_136 and GAMESERVER_138. Installation Server: 1) In the "GameServer\mods" directory of your server, create a "pkodev.mod.reward" folder; 2) Place into the folder the mod DLL file "pkodev.mod.reward.server.13<x>.dll" for your version of GameServer.exe; 3) In the functions.lua file ("GameServer\resource\script\calculate\") write the following script: -- Daily reward system (pkodev.mod.reward) -- Transfer the list of items to the system function GetRewardArrayAdapter(role) -- Get a list of items for daily reward local arr = GetRewardArray(role) -- Transfer the list to the system return arr[1].id, arr[1].number, arr[2].id, arr[2].number, arr[3].id, arr[3].number, arr[4].id, arr[4].number, arr[5].id, arr[5].number, arr[6].id, arr[6].number, arr[7].id, arr[7].number end -- Daily reward system (pkodev.mod.reward) -- Get a list of items for daily reward function GetRewardArray(role) -- Select an item depending on character race local hairstyle_book = function(role) -- List of items -- ID: 931 Lance Trendy Hairstyle Book -- ID: 932 Carsise Trendy Hairstyle Book -- ID: 933 Phyllis Trendy Hairstyle Book -- ID: 934 Ami Trendy Hairstyle Book local items = {931, 932, 933, 934} -- Get character type ID local id = GetChaTypeID(role) -- Return item id depending on the type ID return items[id] or 0 end -- Make a list of items for daily reward local items = { -- Day 1 (Short Sword x 1 or Long Sword x 1 or Fencing Sword x 1) {id = math.random(1, 3), number = 1}, -- Day 2 (Apple x 99 or Bread x 99 or Cake x 99) {id = math.random(1847, 1849), number = 99}, -- Day 3 (Fairy Coin x 50) {id = 855, number = 50}, -- Day 4 (Random fairy ID 183 ... 193 x 1) {id = math.random(183, 193), number = 1}, -- Day 5 (Hairstyle Book x 1) {id = hairstyle_book(role), number = 1}, -- Day 6 (Fairy Ration x 10) {id = 227, number = 10}, -- Day 7 (Refining Gem x 1) {id = 885, number = 1} } -- We have to return an array of items to caller function return items end 4) In MSSQL Management Studio, execute the SQL query: USE GameDB ALTER TABLE character ADD reward VARCHAR(128) NOT NULL DEFAULT '0' WITH VALUES Client: 1) In the "mods" directory of your client create a "pkodev.mod.reward" folder; 2) Place into the folder the mod DLL file "pkodev.mod.reward.client.13x_<x>.dll" for your version of Game.exe; 3) Place the daily reward form texture files "main.png" and "buttons.tga" into the "texture\mods\pkodev.mod.reward\" directory of your client; 4) Add the code for the daily reward form into the "main.clu" script file ("scripts\lua\forms\"): ---------------------------------------------------------------------------------------------------- -- Daily login reward form ---------------------------------------------------------------------------------------------------- -- The form frmReward = UI_CreateForm( "frmReward", FALSE, 366, 158, 150, 200, TRUE, FALSE ) UI_SetFormStyle( frmReward , 0 ) UI_AddFormToTemplete( frmReward, FORM_MAIN ) UI_FormSetIsEscClose( frmReward, FALSE ) UI_SetIsDrag( frmReward, TRUE ) -- Form background frmRewardImg = UI_CreateCompent( frmReward, IMAGE_TYPE, "frmRewardImg", 366, 158, 0, 0 ) UI_LoadImage( frmRewardImg, "texture/mods/pkodev.mod.reward/main.png", NORMAL, 366, 158, 0, 0 ) -- Form title labTitle = UI_CreateCompent( frmReward, LABELEX_TYPE, "labTitle", 400, 150, 10, 7 ) UI_SetCaption( labTitle, "Daily reward!") UI_SetTextColor( labTitle, COLOR_WHITE ) -- Reward button btnGetReward = UI_CreateCompent( frmReward, BUTTON_TYPE, "btnGetReward", 67, 24, 150, 120 ) UI_LoadButtonImage( btnGetReward, "texture/mods/pkodev.mod.reward/main.png", 67, 24, 0, 158, TRUE ) -- Close button btnClose = UI_CreateCompent( frmReward, BUTTON_TYPE, "btnClose", 21, 21, 343, 2 ) UI_LoadButtonImage( btnClose, "texture/mods/pkodev.mod.reward/buttons.tga", 21, 21, 270, 0, TRUE ) UI_SetButtonModalResult( btnClose, BUTTON_CLOSE ) -- Item slots cmdItemSlot0 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot0", 32, 32, 20, 73 ) UI_SetIsDrag( cmdItemSlot0, FALSE ) cmdItemSlot1 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot1", 32, 32, 69, 73 ) UI_SetIsDrag( cmdItemSlot1, FALSE ) cmdItemSlot2 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot2", 32, 32, 118, 73 ) UI_SetIsDrag( cmdItemSlot2, FALSE ) cmdItemSlot3 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot3", 32, 32, 167, 73 ) UI_SetIsDrag( cmdItemSlot3, FALSE ) cmdItemSlot4 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot4", 32, 32, 216, 73 ) UI_SetIsDrag( cmdItemSlot4, FALSE ) cmdItemSlot5 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot5", 32, 32, 265, 73 ) UI_SetIsDrag( cmdItemSlot5, FALSE ) cmdItemSlot6 = UI_CreateCompent( frmReward, COMMAND_ONE_TYPE, "cmdItemSlot6", 32, 32, 314, 73 ) UI_SetIsDrag( cmdItemSlot6, FALSE ) ---------------------------------------------------------------------------------------------------- Mod customization 1) In the GetRewardArray(role) function, write the code that will generate the chain of rewards for the character role for the next seven days. The function must return a table of 7 elements with fields id and number, where id is the ID of the item that is issued as a reward, and number is the number of items in the reward. Each element corresponds to its own day (1st element is the first day, 2nd element is the second day, and so on). Example: function GetRewardArray(role) local items = { -- Day 1: Apple x 20 {id = 1847, number = 20}, -- Day 2: Bread x 40 {id = 1848, number = 40}, -- Day 3: Cake x 60 {id = 1849, number = 60}, -- Day 4: Fairy coin x 55 {id = 855, number = 55}, -- Day 5: Fairy ration x 15 {id = 227, number = 15}, -- Day 6: Bread x 99 {id = 1848, number = 99}, -- Day 7: Cake x 99 {id = 1849, number = 99} } return items end Item IDs and their number can be generated randomly or depending on the character's race, profession, etc 2) By default, the reward period is 24 hours. You can change this value in the mod server-side source code (pkodev.mod.reward.server project, structure.h file), then compile the project: // Reward interval in seconds static const unsigned int interval{ 24 * 60 * 60 }; // 24 hours 3) No client side configuration required. Old style GUI (Thanks to @Masuka00!) main.clu: -- Close button btnClose = UI_CreateCompent( frmReward, BUTTON_TYPE, "btnClose", 14, 14, 342, 4 ) UI_LoadButtonImage( btnClose, "texture/mods/pkodev.mod.reward/main.png", 14, 14, 271, 174, TRUE ) UI_SetButtonModalResult( btnClose, BUTTON_CLOSE ) Download Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  2. [Mod] Cleaning up chats The mod allows GM and HD to delete all messages in players chats (local, world, trade, party, guild, PM, camp). To do this, on the server side for GameServer, the ClearChat(role) lua function is implemented, into which the descriptor of the character controlled by the administrator is passed. Thus, it is possible, for example, to implement a GM command that will clear chats (if there are HandleChat() and GetGmLv() functions present in GameServer.exe). function HandleChat(role, msg) if (msg == "&clearchat") then if (GetGmLv(role) == 99) then ClearChat(role) else SystemNotice(role, "Not enough access!") end return 0 end return 1 end The disadvantage of the mod is that it deletes all chats at once without the ability to specify specific channels. That is, along with the general channels (world, trade, local), the channels with messages to the guild, party, camp and PM will also be cleared. It should also be remembered that the player can remove the .dll mod library from the client and chats will no longer be cleared on command from the server. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.clearchat; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation Client: Place the mod DLL file "pkodev.mod.clearchat.client.13x_<ID>.dll" for your version of Game.exe into the "mods" folder of the game client. Server: 1) Create a file named "pkodev.mod.clearchat.lua" in the following server directory: \GameServer\resource\script\calculate\mods 2) Write the following code into it: -- Print a log print("Loading pkodev.mod.clearchat.lua") -- Clear all chats function ClearChat(role) -- Get moderator's name local name = GetChaDefaultName(TurnToCha(role)) -- Send system command Notice("{system:clearchat}") -- Send message to all players Notice(string.format("Chats have been cleared by moderator [%s]!", name)) end 3) Include the "pkodev.mod.clearchat.lua" file at the beginning of the SkillEffect.lua file (\GameServer\resource\script\calculate) : dofile(GetResPath("script\\calculate\\mods\\pkodev.mod.clearchat.lua")) 4) Use the ClearChat() function to clear chats as you wish. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  3. [Mod] 60 frames per second (60 FPS) This mod increases the graphics rendering speed of the game client from 30 to 60 frames per second. The mod has several problems: 1) When movement speed is too quick, the player's character can be thrown back; 2) When rmovement speed is too quick, the map, NPCs, monsters and players may not have time to load; 3) Animations of characters and objects are played too fast. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.60fps; Version: 1.0; Author: V3ct0r, BotPRO; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation 1) In the "mods" directory of the game client, create a folder named "pkodev.mod.60fps"; 2) Place the DLL file of the mod "pkodev.mod.60fps.client.13x_<ID>.dll" for your version of Game.exe into the folder "mods\pkodev.mod.60fps" of the game client; 3) Place the mod DLL file "pkodev.mod.60fps.impl_<ID>.dll" for your of version Game.exe into the folder "mods\pkodev.mod.60fps\impl" of the game client. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  4. [Mod] Full area map for the region As you know, only the three main regions (Ascaron, Magic Ocean and Deep Blue) have a full area map. When the player presses the "Map" button under the minimap to open the full map of the area, the client sends a packet to the server with the appropriate request. The server reads this packet, decides if the region the player is currently in has a full map, and sends a response to the client. If the answer is "yes", then the client show a large map to the player. If "no", then the player receives the message "This area does not have a full map" in the system: "This area does not have a full map" This mod allows you to add full maps for any region: Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.fullmap; Version: 1.0; Author: V3ct0r; Type: for server (GameServer.exe); Supported executable .exe files: GAMESERVER_136, GAMESERVER_138. Installation 1) In the "mods" directory of your GameServer, create a "pkodev.mod.fullmap" folder; 2) Place into it the mod DLL file "pkodev.mod.fullmap.server.<ID>.dll" for your version of GameServer.exe; 3) Place into it the mod settings file "pkodev.mod.fullmap.cfg" and write in it a list of map names for which you want to add a full map. The name of each map is written on a new line: darkswamp garner2 puzzleworld puzzleworld2 Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  5. [Mod] Colored GM messages (GM notice) This mod allows you to send colored GM messages to players (see screenshot above) using the input field in the game client (ALT + P), or using the GMNotice() function. To make the text of the message colored, you should write the following code at the beginning of the message: {color:color}Message The message color is specified in RGB format as a hexadecimal number (FFRRGGBB). The following example will send the GM message "Hello PKOdev.NET" to the players in orange: {color:FFFF8000}Hello PKOdev.NET! You can also use the GMNotice() function: GMNotice("{color:FFFF8000}Hello PKOdev.NET!") Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.colorgmnotice; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation Place the mod DLL file "pkodev.mod.colorgmnotice.client.13x_<ID>.dll" for your version of Game.exe into the "mods" folder of the game client. Download 1) Binary release; 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  6. [Mod] Server time The mod adds a text label with a clock to the game - the current server time. The server time is taken from the packet ID: 940 that the server sends to the client upon connection, for example: [01-17 10:44:47:879] The clock label is bound to the minimap form "frmMinimap" from the GUI script file "\scripts\lua\forms\minimap.clu". Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.clock; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installation 1) In the "mods" directory of your client, create a "pkodev.mod.clock" folder; 2) Place into it the mod DLL file "pkodev.mod.clock.client.13x_<ID>.dll" for your version of Game.exe; 3) Place into it the mod settings file "pkodev.mod.clock.cfg" and write to the file the desired server time output format in accordance with the documentation for the strftime() function. For example, the format: Server time: %H:%M:%S %d.%m.%y May give the following output: Server time: 10:51:20 17.01.2022 4) In the GUI script file "\scripts\lua\forms\minimap.clu" add the code for the "labClock" text label, which will be responsible for displaying the server time: ------------------------------------------------------------------------------------------ -- Clock label ------------------------------------------------------------------------------------------ labClock = UI_CreateCompent(frmMinimap, LABELEX_TYPE, "labClock", 20, 15, 20, 220) UI_SetCaption(labClock, "Clock") UI_SetTextColor(labClock, COLOR_WHITE) UI_SetLabelExFont(labClock, DEFAULT_FONT, TRUE, COLOR_BLACK) ------------------------------------------------------------------------------------------ Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  7. Идеи для модов В данной теме обсуждаются идеи для создания новых модов, а так же для улучшения уже существующих.
  8. [Mod] Medals (necklaces) with titles The modification allows you to create medals (necklaces) with different titles that appear in brackets before the name of the character (see screenshot). Also, these necklaces allow you to change the color of the names of the characters. The text, color of the title and color of the character's name are specified in the file ItemInfo.txt for items with type 25 (necklace). 1) The text of the title is specified in the description of the item The maximum title length is 15 symbols; 2) The color of the title is specified in the 5th field instead of model for Lance. Color has format FFRRGGBB; 3) The color of the name is specified in the 6th field instead of model for Carsise. Color has format FFRRGGBB; Some examples of medals with titles: XXXX Medal 1 (Red Admin) l0005 10130005 FFFF0000 0 0 0 0 0 25 0 0 0 0 0 1 1 1 1 1 1 32 -1 1 -1 0 0 5 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 0,1000 10000,10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 Admin XXXX Medal 2 (Green maindev) l0005 10130005 FF00FF00 0 0 0 0 0 25 0 0 0 0 0 1 1 1 1 1 1 32 -1 1 -1 0 0 5 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 0,1000 10000,10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 maindev XXXX Medal 3 (Blue PkoDEV) l0005 10130005 FF0000FF 0 0 0 0 0 25 0 0 0 0 0 1 1 1 1 1 1 32 -1 1 -1 0 0 5 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 0,1000 10000,10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 PkoDEV Example of medal with title and colored character name: XXXX Medal 2 l0005 10130005 FF00FF00 FFFF8000 0 0 0 0 25 0 0 0 0 0 1 1 1 1 1 1 32 -1 1 -1 0 0 5 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 0,1000 10000,10000 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 PKOdev.NET Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.title; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation 1) In the "mods" directory of your client, create a "pkodev.mod.title" folder; 2) Place into it the mod DLL file "pkodev.mod.title.client.13x_<ID>.dll" for your version of Game.exe; 3) Add new medals (necklaces) with titles to the file ItemInfo.txt of the server and client according to the example from the topic header. Compile ItemInfo.txt for the client. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  9. [Mod] Displaying the level of items on their icons ("smart icons") Some information appears on the icons of specific items: 1) For items with inserted gems, the level of fusion is displayed; 2) For gems, their level is displayed; 3) For fairies, their level is displayed; 4) For apparels, the inscription "App" is displayed. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.itemlv Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installation Place the mod DLL file "pkodev.mod.itemlv.client.13x_<ID>.dll" for your version of Game.exe into the "mods" folder of the game client. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  10. [Mod] Displaying the name of the item in the apparel In the description of the apparel item, the name of the equipment that is fused in it appears. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.apparel Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installation Place the mod DLL file "pkodev.mod.apparel.client.13x_<ID>.dll" for your version of Game.exe into the "mods" folder of the game client. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  11. [Mod] Flying effect for wings This modification for the game client allows you to add a flight effect to any Wings (items with type 44), similar to the effect of the Wings of Rebirth. Information about the modification Name: pkodev.mod.wings; Version: 1.1; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installing the modification 1. Install mod loading system pkodev.mod.loader if it hasn't already been installed; 2. Place the mod DLL file pkodev.mod.wings.client.13x_{ID}.dll for your version of Game.exe and the mod settings file pkodev.mod.wings.cfg in the mods\pkodev.mod.wings folder of the game client. 3. Open the mod settings file pkodev.mod.wings.cfg and write in it the list of IDs of the wings to which you want to apply the flight effect. Each ID is written on a new line, for example: 935 936 937 This will apply the flying effect to Elven Wings, Butterfly Wings and Angelic Wings respectively. 4. Modification installation completed! Launch the game client and make sure the modification works. Download 1) Modification binary files for the client (.dll); 2) Repository on GitHub with the source code of the modification for Visual Studio 2022 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  12. [Mod] Highlight friends and enemies with color This modification highlights friendly and hostile players on the screen: the names of the characters change color, and colored circles are displayed under the characters (see screenshot above). If there are enemies near the player's character, a warning icon is displayed next to the character's avatar: Characters are considered friendly if they: 1) Are in the same party; 2) Are in the same guild; 3) Are in the same fraction. The mod only works on PvP maps that are specified in the settings. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.enemy; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation 1) In the "mods" directory of your client, create a "pkodev.mod.enemy" folder; 2) Place into it the mod DLL file "pkodev.mod.enemy.client.13x_<ID>.dll" for your version of Game.exe; 3) Place into it the mod settings file "pkodev.mod.enemy.cfg" and customize it as you wish: // pkodev.mod.enemy settings file // (c) V3ct0r from PKOdev.NET // 02/16/2022 [show] main_cha = true // Should the player character be displayed as a teammate? colored_name = true // Colorize character names? colored_circle = true // Show circles under characters? [color] enemy_color = FFFF0000 // Enemy character name color (in the hexadecimal form: FFRRGGBB) friend_color = FF00FF00 // Teammate character name color (in the hexadecimal form: FFRRGGBB) [icon] warning_show = true // Should the 'warning' icon be shown when enemies are near? warning_x = 208 // 'x' position of the icon on the screen warning_y = 16 // 'y' position of the icon on the screen [map] maps = garner,magicsea,darkblue // Maps on which the mod is enabled 4) In the "texture" directory of the game client, create a folder "mods", and in it a subfolder "pkodev.mod.enemy". Place the "warning.png" icon from the archive with the mod into this subfolder. You can replace this icon with any other with the same name, 32 x 32 pixels and in .png format. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  13. Ideas for mods This topic discusses ideas for creating new mods, as well as for improving existing ones.
  14. [Mod] Editing the limits of .txt tables With the help of this mod for the "PKODev.NET mod loader" system, you can easily edit the limits for .txt/.bin files of the client and server without the need to edit Game.exe and GameServer.exe in the HEX editor. The limits are edited in the text file pkodev.mod.tablelimit.cfg: areaset = 300 character_lvup = 120 characterinfo = 2500 forgeitem = 12 hairs = 500 int_cha_item = 32 iteminfo = 6000 lifelvup = 1000 saillvup = 1000 shipinfo = 120 shipiteminfo = 500 skilleff = 240 skillinfo = 500 characterposeinfo = 100 chaticons = 100 elfskillinfo = 100 eventsound = 30 itempre = 100 itemrefineeffectinfo = 5000 itemrefineinfo = 20000 itemtype = 100 magicgroupinfo = 10 magicsingleinfo = 100 mapinfo = 100 musicinfo = 500 notifyset = 100 objevent = 10 resourceinfo = 3000 sceneffectinfo = 14000 sceneobjinfo = 800 selectcha = 60 serverset = 100 shadeinfo = 14000 stoneinfo = 100 terraininfo = 100 It is not necessary to write to the file all limits If you need to edit only some of them: iteminfo = 12000 characterinfo = 6000 mapinfo = 500 GameServer.exe tables (13) Game.exe tables (31) Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.tablelimit; Version: 1.0; Author: V3ct0r; Type: for client and server (Game.exe and GameServer.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5, GAMESERVER_136 and GAMESERVER_138. Installation 1) In the "mods" directory of your server or client, create a "pkodev.mod.tablelimit" folder; 2) Place into it the mod DLL file "pkodev.mod.tablelimit.<client/server>.<x>.dll" for your version of Game.exe or GameServer.exe; 3) Place into it the mod settings file "pkodev.mod.tablelimit.cfg"; 4) Edit the "pkodev.mod.tablelimit.cfg" file at your own discretion - specify the required limit values for each .txt/.bin table file: <table_name> = <value> Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  15. [Мод] Выделение друзей и врагов цветом Данная модификация выделяет на экране дружественных и враждебных игроков: имена персонажей меняют цвет, а под персонажами отображаются цветные круги (см. скриншот выше). Если поблизости с персонажем игрока есть враждебные игроки, то рядом с аватаром персонажа отображается предупреждающая иконка: Персонажи считаются дружественными, если они: 1) Находятся в одном отряде; 2) Находятся в одной гильдии; 3) Находятся в одной фракции. Мод работает только на PvP-картах, которые указаны в настройках. Требования Установленный Загрузчик модов для сервера и клиента (PKOdev.NET mod loader). Информация о моде Название: pkodev.mod.enemy; Версия: 1.0; Автор: V3ct0r; Тип: для клиента (Game.exe); Поддерживаемые исполняемые .exe файлы: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 и GAME_13X_5. Установка 1) В директории "mods" Вашего клиента создайте папку "pkodev.mod.enemy"; 2) Поместите в неё файл DLL-библиотеки мода "pkodev.mod.enemy.client.13x_<x>.dll" для Вашей версии Game.exe. 3) Поместите в неё файл настроек мода "pkodev.mod.enemy.cfg" и настройте его по своему усмотрению: // pkodev.mod.enemy settings file // (c) V3ct0r from PKOdev.NET // 02/16/2022 [show] main_cha = true // Выделять ли персонажа игрока как дружественного? colored_name = true // Выделять ли имена персонажей цветом? colored_circle = true // Отображать ли цветные круги под персонажами? [color] enemy_color = FFFF0000 // Цвет имени враждебного персонажа (в шестнадцатеричной форме: FFRRGGBB) friend_color = FF00FF00 // Цвет имени дружественного персонажа (в шестнадцатеричной форме: FFRRGGBB) [icon] warning_show = true // Отображать ли предупреждающую иконку когда рядом враги? warning_x = 208 // Координата X иконки на экране warning_y = 16 // Координата Y иконки на экране [map] maps = garner,magicsea,darkblue // Карты на которых работает мод 4) В директории "texture" игрового клиента создайте папку "mods", а в ней подпапку "pkodev.mod.enemy". Поместите в данную подпапку иконку "warning.png" из архива с модом. Вы можете заменить эту иконку на любую другую с тем с же именем, размерами 32 на 32 пикселя и в формате .png. Скачать 1) Бинарные файлы мода (.dll); 2) Исходный код мода для Visual Studio 2019 Community (C++). Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
  16. [Мод] Эффект полета для крыльев Данная модификация для клиента позволяет добавлять к любым Крыльям (предметы с типом 44) эффект полета, аналогичный эффекту Крыльев перерождения. Информация о модификации Название: pkodev.mod.wings; Версия: 1.1; Автор: V3ct0r; Тип: для клиента (Game.exe); Поддерживаемые исполняемые .exe файлы: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 и GAME_13X_5. Установка модификации 1. Установите систему загрузки модов pkodev.mod.loader, если она не была установлена ранее. 2. Поместите файл DLL-библиотеки мода pkodev.mod.wings.client.13x_{ID}.dll для Вашей версии Game.exe и файл настроек мода pkodev.mod.wings.cfg в папку mods\pkodev.mod.wings игрового клиента. 3. Откройте файл настроек мода pkodev.mod.wings.cfg и запишите в него список ID крыльев, к которым необходимо применить эффект полета. Каждый ID записывается с новой строки, например: 935 936 937 В результате эффект полета будет применен к Эльфийским крыльям, Крыльям бабочки и Ангельским крыльям соответственно. 4. Установка модификации завершена! Запустите игровой клиент и убедитесь, что модификация работает. Скачать 1) Бинарные файлы модификации для клиента (.dll); 2) Репозиторий на GitHub с исходным кодом модификации для Visual Studio 2022 Community на языке C++. 3) Система загрузки модов pkodev.mod.loader. Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
  17. I found @V3ct0r's pkodev modloader quite a while back and had no idea what I was doing at the time but after some playing around and creating a few "test" mods, I absolutely think this is the best thing to happen to precompiled ToP binaries in forever, however I started a new project fixing and adding new forms ingame when I hit a roadblock. While most of the classes used in ToP are easily found with Ida I could not find CTextButton and a few others at all only the address for their procedures, I would think the class would've been recoverable as a struct that I could recreate and have functions get called when it's clicked et cetera. Would I just need to recreate the class from source?(but then with vtables?) I'm a bit lost at the moment and any help is appreciated! /// gui::CForm* frmTest = gui::CUIInterface::Instance().FindForm("frmTest"); if (frmTest != nullptr) { CTextButton* btnTest = frmTest->Find<CTextButton>("btnTest"); if (btnTest != nullptr) { btnTest.evtMouseClick = ClickTestButton; } } /// void ClickTestButton(CGuiData* sender,int x, int y, MouseClickState key){ //Do whatever } I suppose this question is more pointed to @V3ct0r but I'm happy for a response from anyone with the knowledge
  18. [Mod] Contracts system This system is a "Monster Hunt" type quest, the purpose of which is to defeat a certain amount of specific monsters. A player is given a special item - “Contract”, which indicates which monster and how many the player have to defeat. As monsters are defeated, the player's current progress is updated in the "Contract". After defeating the required number of monsters, the "Contract" is considered completed, and the player can receive a reward by using the "Contract" item. The system consists of a pkodev.mod.loader modification for the game client (Game.exe) and a Lua script for the game server (GameServer.exe). Modification of the client is necessary to visualize the specified characteristics of the item in the hint field for the "Contract" when the player hover the mouse cursor over it's item. The target monster ID, the number of monsters already defeated, and the number of monsters needed to complete the "Contract" are stored in the following item stats: ITEMATTR_VAL_STR, ITEMATTR_VAL_DEX, and ITEMATTR_VAL_AGI, respectively. The purpose of the mod is to display these item characteristics in a form understandable to the player. For example, if ITEMATTR_VAL_STR = 103, ITEMATTR_VAL_DEX = 5, and ITEMATTR_VAL_AGI = 10, then the player will see the following information when hovering the mouse over "Contract": Hunt: 'Forest Spirit' x 10 Progress: 5 / 10 The Lua script for the game server is the core of the Contracts system, which contains the System settings and the logic of its operation. For example, when defeating next monster, the script will search the character's inventory for a suitable active "Contract", and if such the item is found, the System will update its state. An important setting of the script is the function that is necessary for issuing a reward after the player successfully completes the "Contract". Some features of the System: 1. "Contract" can be picked up, thrown away, transferred to another player, put in a bank or sold; 2. If a player has multiple "Contracts" in his inventory to hunt the same monster, then when defeating this monster, the "Contract" is selected randomly; 3. To receive a reward after completing a "Contract", the player should use an item of the "Contract", for example by double-clicking on it. The player will see a corresponding message in the system chat if the "Contract" has not yet been completed; 4. The content and amount of the reward are determined by the administrator in a special function of the System script; 5. ID and item type for "Contract" must be unique and set by the administrator in the System settings. The default item type is 99, the default item ID is undefined. Information about the modification Name: pkodev.mod.contract; Version: 1.1; Author: V3ct0r; Type: for the game client (Game.exe); Supported executable files (.exe): GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installing the Contracts system Game server 1. Add a "Contract" item to the GameServer\resource\ItemInfo.txt file. To do this, select any suitable ID (XXXX) and item type (99 by default): XXXX Contract n0184 10130005 0 0 0 0 0 00 99 0 0 0 0 0 1 1 1 1 1 1 0 -1 0 -1 0 0 -1 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 10,10 0,0 0 0 0 0 0 0 0 0 0 ItemUse_PKOdevContract 0 0 0 0 0 0 After completion you will receive a reward! 2. Place Lua script pkodev.contract.lua in GameServer\resource\script\calculate\mods directory (create mods folder if necessary). 3. Open the pkodev.contract.lua file and configure it as follows: 3.1 Write the "Contract" item ID from ItemInfo.txt (XXXX) to the item_id variable: item_id = XXXX, 3.2 In the CompletionCallback() function, write a code that will give players a reward after completing "Contracts". By default, the function gives a player 1,000 gold coins, a random item (Refining Gem x 1, or Gem of Rage x 2, or Cake x 60, or Fairy of Luck x 1) and launches fireworks: CompletionCallback = function(role, item) -- Give 1,000 gold AddMoney (role, 0, 1000) -- Set of items local arr = { {id = 885, count = 1 }, -- Refining Gem x 1 {id = 863, count = 2 }, -- Gem of Rage x 2 {id = 1849, count = 60}, -- Cake x 60 {id = 231, count = 1 } -- Fairy of Luck x 1 } -- Give a random item local idx = math.random(1, table.getn(arr)) GiveItem(role, 0, arr[idx].id , arr[idx].count, 4) -- Launch fireworks PlayEffect(role, 361) end 3.3 Open the file GameServer\resource\script\calculate\SkillEffect.lua and at the very beginning write the line: dofile(GetResPath("script\\calculate\\mods\\pkodev.contract.lua")) 4. The Contracts system has been successfully installed on your server. Congratulations! Also take a look at @Angelix's Contract System script implementation. It is more flexible and advanced than the one suggested above. Description of the script and installation instructions can be found in the corresponding topic: Game client 1. Add a "Contract" item to the Client\scripts\table\ItemInfo.txt file (see above "Installing the Contracts system" > "Game server" > point 1). Compile ItemInfo.txt. 2. Add to the file Client\scripts\table\StringSet.txt the following strings that a player will see when hovering the mouse over the "Contract": [1000] "(Completed)" [1001] "(Active)" [1002] "Hunt: '{0}' x {1}" [1003] "Progress: {0} / {1}" Note 1: If IDs of strings 1000 - 1003 are already taken, then write any free IDs instead. Note 2: After adding these strings to the StringSet.txt file, delete the StringSet.bin file if it exists, otherwise the changes will not be applied. Note 3: In string 1002, marker {0} is the name of the monster, and {1} is the number of monsters to defeat. In string 1003 marker {0} indicates the number of monsters already defeated, marker {1} is similar to string 1002. 3. Install mod loading system pkodev.mod.loader if it hasn't already been installed. 4. Place the mod DLL file pkodev.mod.contract.client.13x_{ID}.dll for your version of Game.exe and the mod settings file pkodev.mod.contract.json in the mods\pkodev.mod.contract folder of the game client. 5. Open the mod's settings file pkodev.mod.contract.json and write the following parameters into it according to your choice: 1. itemType - type of the item "Contract" specified in the ItemInfo.txt file. The default value is 99. 2. colorCompleted - the color of the "(Completed)" label in the hint for the "Contract" item in the format 0xAARRGGBB. The default value is 0xFF00FF00 (Green). 3. colorActive - the color of the "(Completed)" label in the hint for the "Contract" item in the format 0xAARRGGBB. The default value is 0xFFFFA500 (Orange). 4. STRING_001 - string ID for the "(Completed)" label from the StringSet.txt file. The default value is 1000. 5. STRING_002 - string ID for the "(Active)" label from the StringSet.txt file. The default value is 1001. 6. STRING_003 - string ID for the "Hunt: '{0}' x {1}" label from the StringSet.txt file. The default value is 1002. 7. STRING_004 - string ID for the "Progress: {0} / {1}" label from the StringSet.txt file. The default value is 1003. Note: This file can be left unchanged if you used the default values in the ItemInfo.txt and StringSet.txt files. 6. The contracts system setup for the game client is now complete! Creating "Contracts" and issuing them to the players "Contracts" are created using the contract.create() function, which takes as its arguments the handle of a character to which the contract is to be issued, the ID of a monster a player will need to defeat, and a number of monsters that the player have to defeat. As a result, the function returns a tuple of three elements: success flag, new item descriptor, and item slot number in the character's inventory. Syntax: local <Result LUA_TRUE|LUA_FALSE>, <Item descriptor>, <Item slot> = contract.create(<Character descriptor>, <Monster ID>, <Number of monsters>) Example: local ret, item, pos = contract.create(role, 103, 7) As the result, a "Contract" will be created to defeat the seven Forest Spirits, which will appear in the inventory of the role character. In case of an error, the function will return the value LUA_FALSE to the ret variable and write a log message to the pkodev.contract.txt file. Note: Creation of "Contracts" can be organized, for example, through a special NPC or other item. Useful links 1) Modification binary files for the client (.dll); 2) The file with the modification settings for the client (pkodev.mod.contract.json); 3) Repository on GitHub with the source code of the modification for Visual Studio 2022 Community (C++); 4) Lua script of the Contracts system for the game server; 5) ItemInfo.txt with an example of the "Contract" item; 6) Strings for the file StringSet.txt; 7) Mod loading system pkodev.mod.loader. If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  19. [Mod] Displaying coordinates under NPC This modification for the game client displays coordinates under non-player characters (NPC) and highlights NPC names in yellow. Information about the modification Name: pkodev.mod.npcpos; Version: 1.1; Author: V3ct0r; Type: for the game client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 and GAME_13X_5. Installing the modification 1. Install mod loading system pkodev.mod.loader if it hasn't already been installed; 2. Place the mod DLL file pkodev.mod.npcpos.client.13x_{ID}.dll for your version of Game.exe in the mods folder of the game client; 3. Modification installed! Customizing the modification If necessary, the coordinates display format can be changed in the "dllmain.cpp" file in the "void __fastcall hook::CHeadSay__Render(void* This, void*, structure::D3DXVECTOR3& Pos)" function: const std::string text = std::format("({0}, {1})", cha->GetX(), cha->GetY()); The color used to highlight the NPC names can be changed in the same function: utils::set<unsigned int, 0x38>(This, 0xFFFFFF00); // Set NPC color name (Yellow) Note: After the changes are made, you need to rebuild the modification. Download 1) Modification binary files for the client (.dll); 2) Repository on GitHub with the source code of the modification for Visual Studio 2022 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  20. [Мод] Система контрактов Данная система представляет собой квест типа: "Охота на монстров", целью которого является добыча персонажем игрока некоторого количества определенных монстров. Игроку выдается специальный предмет - "Контракт", в котором указано на какого монстра и в каком количестве игроку предстоит охотиться. По мере охоты, в контракте обновляется текущий прогресс игрока. После добычи необходимого числа монстров контракт считается выполненным, и игрок может получить награду, использовав предмет "Контракта". Система состоит из двух частей: модификация pkodev.mod.loader для игрового клиента (Game.exe) и Lua-скрипт для игрового сервера (GameServer.exe). Модификация клиента необходима для визуализации заданных характеристик предмета в поле-подсказке для предмета "Контракта" при наведении на него курсора мыши. ID монстра-цели, количество добытых монстров и количество монстров, необходимых для завершения "Контракта", записываются в следующие характеристики предмета: ITEMATTR_VAL_STR, ITEMATTR_VAL_DEX и ITEMATTR_VAL_AGI соответственно. Задачей мода является отображение этих характеристик в понятном для игрока виде. Например, если ITEMATTR_VAL_STR = 103, ITEMATTR_VAL_DEX = 5, а ITEMATTR_VAL_AGI = 10, то игрок при наведении мыши на "Контракт" увидит следующую информацию: Охота: 'Лесной дух' x 10 Добыто: 5 / 10 Lua-скрипт для игрового сервера является ядром Системы контрактов, в котором содержатся настройки системы и логика её работы. Например, при добыче очередного монстра, скрипт будет искать в инвентаре персонажа подходящий активный "Контракт", и если такой предмет будет найден, то Система обновит его состояние. Важной настройкой скрипта является функция, которая необходима для выдачи награды после успешного завершения "Контракта" игроком. Некоторые особенности системы: 1) "Контракт" можно подобрать, выбросить, передать другому игроку, положить в банк или продать; 2) Если у игрока в инвентаре несколько "Контрактов" на охоту на одного и того же монстра, то при добыче данного монстра "Контракт" выбирается случайным образом; 3) Для получения награды после завершения "Контракта", игрок должен использовать предмет "Контракта", например, с помощью двойного клика мыши по нему. Если "Контракт" еще не завершен, то игрок увидит соответствующее сообщение в систему; 4) Состав и количество награды определяются администратором в специальной функции скрипта системы; 5) ID и тип предмета для "Контракта" должны быть уникальными и задаются администратором в настройках Системы. Тип предмета по умолчанию равен 99, ID предмета по умолчанию не определен. Информация о модификации Название: pkodev.mod.contract; Версия: 1.1; Автор: V3ct0r; Тип: для игрового клиента (Game.exe); Поддерживаемые исполняемые файлы (.exe): GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 и GAME_13X_5. Установка Системы контрактов Игровой сервер 1. Добавьте в файл GameServer\resource\ItemInfo.txt предмет для "Контракта". Для этого выберите подходящий ID (XXXX) и тип предмета (по умолчанию 99): XXXX Контракт n0184 10130005 0 0 0 0 0 00 99 0 0 0 0 0 1 1 1 1 1 1 0 -1 0 -1 0 0 -1 -1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0,0 0 10,10 0,0 0 0 0 0 0 0 0 0 0 ItemUse_PKOdevContract 0 0 0 0 0 0 После завершения Вы получите награду! где XXXX - любой незанятый ID. 2. Поместите Lua-скрипт pkodev.contract.lua в директорию GameServer\resource\script\calculate\mods (при необходимости создайте каталог mods). Примечание: Скрипт pkodev.contract.lua отправляет игрокам различные сообщения на английском языке. Вероятно, Вам будет необходимо перевести эти сообщения на русский язык. 3. Откройте файл pkodev.contract.lua и настройте его следующим образом: 3.1 В переменную item_id запишите ID предмета из ItemInfo.txt (XXXX): item_id = XXXX, 3.2 В функции CompletionCallback() запишите код, который будет выдавать игроку награду после выполнения "Контракта". По умолчанию функция выдает игроку 1,000 золотых монет, случайный предмет (Очищающий самоцвет x 1, или Самоцвет ярости x 2, или Кекс x 60, или Фея удачи x 1) и запускает фейерверк: CompletionCallback = function(role, item) -- Выдать 1,000 золотых монет AddMoney (role, 0, 1000) -- Список предметов local arr = { {id = 885, count = 1 }, -- Очищающий самоцвет x 1 {id = 863, count = 2 }, -- Самоцвет ярости x 2 {id = 1849, count = 60}, -- Кекс x 60 {id = 231, count = 1 } -- Фея удачи x 1 } -- Выдать случайный предмет local idx = math.random(1, table.getn(arr)) GiveItem(role, 0, arr[idx].id , arr[idx].count, 4) -- Запустить фейерверк PlayEffect(role, 361) end 3.3 Откройте файл GameServer\resource\script\calculate\SkillEffect.lua и в самом начале запишите строку: dofile(GetResPath("script\\calculate\\mods\\pkodev.contract.lua")) 4. Система контрактов была успешно установлена на Ваш сервер. Поздравляю! Также обратите внимание на реализацию скрипта Системы контрактов от @Angelix. Она более гибкая и продвинутая по сравнению с той, что предлагается выше. Описание скрипта и инструкцию по установке можно найти в соответствующей теме: Игровой клиент 1. Добавьте в файл Клиент\scripts\table\ItemInfo.txt предмет для "Контракта" (см. выше "Установка Системы контрактов" > "Игровой сервер" > пункт 1. Скомпилируйте ItemInfo.txt. 2. Добавьте в файл Клиент\scripts\table\StringSet.txt следующие строки, которые увидит игрок при наведении курсора мыши на предмет "Контракта": [1000] "(Выполнен)" [1001] "(Выполняется)" [1002] "Охота: '{0}' x {1}" [1003] "Добыто: {0} / {1}" Примечание 1: Если ID строк 1000 - 1003 уже заняты, то вместо них запишите свободные ID. Примечание 2: После добавления данных строк в файл StringSet.txt, удалите файл StringSet.bin, если он существует, иначе изменения не применятся. Примечание 3: В строке 1002 маркер {0} обозначает название монстра, а {1} - количество монстров, которое необходимо добыть. В строке 1003 маркер {0} обозначает число уже добытых монстров, маркер {1} по значению аналогичен строке 1002. 3. Установите систему загрузки модов pkodev.mod.loader, если она не была установлена ранее. 4. Поместите файл DLL-библиотеки мода pkodev.mod.contract.client.13x_{ID}.dll для Вашей версии Game.exe и файл настроек мода pkodev.mod.contract.json в папку mods\pkodev.mod.contract игрового клиента. 5. Откройте файл настроек мода pkodev.mod.contract.json и запишите в него следующие параметры по Вашему усмотрению: 1. itemType - тип предмета "Контракта", указанный в ItemInfo.txt. По умолчанию 99. 2. colorCompleted - Цвет метки "(Выполнен)" во всплывающей подсказке предмета "Контракта" в формате 0xAARRGGBB. По умолчанию 0xFF00FF00 (Зеленый). 3. colorActive - Цвет метки "(Выполняется)" во всплывающей подсказке предмета "Контракта" в формате 0xAARRGGBB. По умолчанию 0xFFFFA500 (Оранжевый). 4. STRING_001 - ID строки для метки "(Выполнен)" из файла StringSet.txt. По умолчанию 1000. 5. STRING_002 - ID строки для метки "(Выполняется)" из файла StringSet.txt. По умолчанию 1001. 6. STRING_003 - ID строки для метки "Охота: '{0}' x {1}" из файла StringSet.txt. По умолчанию 1002. 7. STRING_004 - ID строки для метки "Добыто: {0} / {1}" из файла StringSet.txt. По умолчанию 1003. Примечание: Данный файл можно не редактировать, если Вы использовали значения по умолчанию в файлах ItemInfo.txt и StringSet.txt. 6. Настройка клиента завершена! Создание "Контрактов" и их выдача игрокам "Контракты" создаются с помощью функции contract.create(), которая в качестве своих аргументов принимает дескриптор персонажа, которому выдается контракт, ID монстра, на которого игроку предстоит охотиться, и количество монстров, которое игрок должен добыть. В результате функция возвращает кортеж из трех элементов: флаг успеха, дескриптор созданного предмета и номер ячейки в инвентаре персонажа. Синтаксис: local <Результат (LUA_TRUE или LUA_FALSE)>, <Дескриптор предмета>, <Ячейка в инвентаре> = contract.create(<Дескриптор персонажа>, <ID монстра>, <Число монстров>) Пример: local ret, item, pos = contract.create(role, 103, 7) Синтаксис: local <Результат LUA_TRUE|LUA_FALSE>, <Дескриптор предмета>, <Ячейка предмета> = contract.create(<Дескриптор персонажа>, <ID монстра>, <Число монстров>) В результате будет создан "Контракт" на охоту на семерых Лесных духов, который появится в инвентаре персонажа role. В случае ошибки функция вернет в переменную ret значение LUA_FALSE и запишет лог в файл pkodev.contract.txt. Примечание: Выдачу "Контрактов" можно организовать, например, через специального NPC или другой предмет. Полезные ссылки 1) Lua-скрипт системы для игрового сервера; 2) ItemInfo.txt с примером предмета "Контракта"; 3) Строки для файла StringSet.txt; 4) Бинарные файлы модификации для клиента (.dll); 5) Файл с настройками модификации для клиента; 6) Репозиторий на GitHub с исходным кодом модификации для Visual Studio 2022 Community на языке C++; 7) Система загрузки модов pkodev.mod.loader. Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
  21. [Мод] Отображение координат под NPC Данная модификация отображает координаты под неигровыми персонажами (NPC) и выделяет названия NPC желтым цветом. Информация о модификации Название: pkodev.mod.npcpos; Версия: 1.1; Автор: V3ct0r; Тип: для клиента (Game.exe); Поддерживаемые исполняемые .exe файлы: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 и GAME_13X_5. Установка модификации 1. Установите систему загрузки модов pkodev.mod.loader, если она не была установлена ранее. 2. Поместите файл DLL-библиотеки мода pkodev.mod.npcpos.client.13x_{ID}.dll для Вашей версии Game.exe в папку mods игрового клиента. 3. Модификация установлена! Настройка модификации (необязательно) При необходимости формат вывода координат редактируется в файле "dllmain.cpp" в функции "void __fastcall hook::CHeadSay__Render(void* This, void*, structure::D3DXVECTOR3& Pos)": const std::string text = std::format("({0}, {1})", cha->GetX(), cha->GetY()); Цвет, которым выделяются названия NPC, изменяется в той же функции: utils::set<unsigned int, 0x38>(This, 0xFFFFFF00); // Set NPC color name (Yellow) Примечание: После произведенных изменений необходимо пересобрать модификацию. Скачать 1) Бинарные файлы модификации для клиента (.dll); 2) Репозиторий на GitHub с исходным кодом модификации для Visual Studio 2022 Community на языке C++; 3) Система загрузки модов pkodev.mod.loader. Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
  22. [Мод] Улучшение характеристик персонажа зажатием левой кнопки мыши Модификация добавляет в клиент игры возможность автоматической прокачки характеристик персонажа путем зажатия левой кнопки мыши на кнопке "+" рядом с соответствующей характеристикой на форме "Персонаж". Мод по мотивам темы от @Graf'а: Информация о модификации Название: pkodev.mod.statsclicker; Версия: 1.0; Автор: V3ct0r; Тип: для клиента (Game.exe); Поддерживаемые исполняемые .exe файлы: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4 и GAME_13X_5. Установка модификации 1. Установите систему загрузки модов pkodev.mod.loader, если она не была установлена ранее. 2. Поместите файл DLL-библиотеки мода pkodev.mod.statsclicker.client.13x_{ID}.dll для Вашей версии Game.exe в папку mods игрового клиента. 3. Модификация установлена! Скачать 1) Бинарные файлы модификации для клиента (.dll); 2) Репозиторий на GitHub с исходным кодом модификации для Visual Studio 2022 Community на языке C++; 3) Система загрузки модов pkodev.mod.loader. Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
  23. [Mod] Fixing instant respawn of killed monsters after GameServer restart This mod for the "PKODev.NET mod loader" system fixes the problem of instant respawn of killed monsters after restarting the server. Imagine a situation: you have a boss monster on your server, for example "Black Dragon", the respawn time of which is 168 hours (a week). Your players kill it and, according to the rules of the game, next time they can kill it in a week. Then you decide to restart the server (update, maintenance, etc), but the game server is designed in such a way that all the monsters written in the scripts appear immediately after it starts. As a result, the respawn of the "Black Dragon" will occur much earlier than in 168 hours. This situation can hit the server economy or give an advantage to some players and guilds. This is the second version of this mod - 1.1. In version 1.0, there was a critical bug related to the fact that one binary file for several instances of GameServer.exe was used to store information about killed monsters. For example, GameServer "A" writes a list of killed monsters to a file, then GameServer "B" writes a different list of killed monsters to the same file. As a result, the list of killed GameServer "A" monsters is lost due to the overwriting of the data file. In the new version of the mod, all data about killed monsters are stored in separate files for each map of the game world. Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.mobspawn; Version: 1.1; Author: V3ct0r; Type: for server (GameServer.exe); Supported executable .exe files: GAMESERVER_136 and GAMESERVER_138. Installation 1) In the "mods" directory of your GameServer, create a "pkodev.mod.mobspawn" folder; 2) Place into it the mod DLL file "pkodev.mod.mobspawn.server.13<x>.dll" for your version of GameServer.exe; 3) Place into it the "pkodev.mod.mobspawn.cfg" configuration file; 4) In the mod directory "pkodev.mod.mobspawn" create an empty "data" folder; 5) Write to the configuration file "pkodev.mod.mobspawn.cfg" the IDs of the monsters you want to control the respawn. Each ID is written on a new line. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  24. [Mod] Displaying the cooldown of skills The mod shows the time on the skill icons, which remains until full recovery (see animation above). Based on @Snre3n's code posted in thread "Source Code Features/Concepts Releases": Requirements Installed mod loading system for server and client (PKOdev.NET mod loader). Modification information Name: pkodev.mod.cooldown; Version: 1.0; Author: V3ct0r; Type: for client (Game.exe); Supported executable .exe files: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Installation Place the mod DLL file "pkodev.mod.cooldown.client.13x_<ID> .dll" for your version of Game.exe into the "mods" folder of the game client. Download 1) Binary release (.dll); 2) The source code of the mod for Visual Studio 2019 Community (C++). If you encounter any problem, bug or have any questions, then feel free to write in this thread.
  25. [Мод] Отключение сообщений об ошибках при компиляции .txt-таблиц (table_bin) Данный мод отключает многочисленный вывод ошибок в диалоговом окне (MessageBox) при отсутствии некоторых .txt-таблиц в процессе их компиляции с помощью параметра запуска клиента table_bin. Требования Установленный Загрузчик модов для сервера и клиента (PKOdev.NET mod loader). Информация о моде Название: pkodev.mod.nomsgbin; Версия: 1.0; Автор: V3ct0r; Тип: для клиента (Game.exe); Поддерживаемые исполняемые .exe файлы: GAME_13X_0, GAME_13X_1, GAME_13X_2, GAME_13X_3, GAME_13X_4, GAME_13X_5. Установка Поместите файл DLL-библиотеки мода "pkodev.mod.nomsgbin.client.13x_<ID>.dll" для Вашей версии Game.exe в папку "mods" игрового клиента. Скачать 1) Бинарные файлы мода (.dll); 2) Исходный код мода для Visual Studio 2019 Community (C++). Если Вы столкнулись с какой-либо проблемой, багом или у Вас возникли вопросы, то пишите в данной теме.
×
×
  • Create New...