Jump to content
View in the app

A better way to browse. Learn more.

Shaiya.gg

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

An effort to improve episode 6 support for private servers

Please read everything before you use anything in the repository. The library is designed to be reference material for people that back-engineer the game. You can view the source code here.

 

Thanks:

 

[mention=2]Cups[/mention] for being my inspiration and helping me to improve. I doubt this would exist without your contributions to this community.

[mention=25]joins.dj[/mention] for being a good friend and letting me pick your brain whenever I want.

[mention=26]Garret[/mention] for the Shaiya Essentials project.

[mention=5]cwifo[/mention], [mention=1]Shaco[/mention] and [mention=10]ItsBeno[/mention] for helping me test most of the features.

[mention=39]gualoki[/mention], [mention=17]melihxrist[/mention] and [mention=11]razor[/mention] for reporting critical bugs.

[mention=1]Shaco[/mention] for unpacking the 6.4 PT client.

[mention=35]rn4444[/mention] for testing the libraries and providing excellent feedback.

[mention=51]xarel[/mention] for several helpful bug reports.

 

Update:

 

I'll continue to update the project occasionally, but I'm not interested in adding new features. The issues tab will be disabled. I have a few reliable people who will let me know when something is wrong.

Edited by Bowie

  • Replies 95
  • Views 12.6k
  • Created
  • Last Reply

Top Posters In This Topic

Featured Replies

After some time here I am again. I hope this message find you well.

 

In this opportunity, my question is about a more superficial issue.

 

A few days ago one of the players asked me why when equipping a skin the face of the character was changed by the default face, to which to tell the truth I did not know how to answer so I did the test and indeed it is a "problem" that happens.

 

I'm using the last version of both dlls compiled for an EP6.4 server+client.

 

Is this a known behavior?

Hey, this is how costumes have always worked. This is because you define also a face to use in the DualLayerClothes.SData , by default on most servers all costumes uses the first one.

You can edit what face every costume shows, but it have little uses.

Who knew that version 1.38 could not be compiled

This is an error message:

 

[ATTACH type=full]53[/ATTACH]

  • Author
that's a C++ 23 feature. maybe the SDK isn't on your machine.

Edited by Bowie

这是 C++ 23 的一项功能。也许 SDK 不在您的计算机上。

thank you [mention=7]Bowie[/mention]

  • 1 month later...

hi, i would like to release command manager extension with an example, its handles the /mmake command for ps_game.

 

#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <include/main.h>
#include <include/util.h>
#include <iostream>
#include <sstream>
#include <vector>
#include <include/shaiya/include/CWorld.h>
#include <include/shaiya/include/CZone.h>

using namespace shaiya;

namespace command_manager
{
   std::string output;

   int execute(const char* input, int cmd_case) {
       std::istringstream stream(input);
       std::vector<std::string> args;

       std::string temp;
       stream >> temp;
       while (stream >> temp) {
           args.push_back(temp);
       }

       switch (cmd_case) {
       case 69:
       {
           auto map = std::stoi(args.at(0));
           auto mobId = std::stoi(args.at(1));
           auto count = std::stoi(args.at(2));
           auto x = std::stof(args.at(3));
           auto y = std::stof(args.at(4));
           auto z = std::stof(args.at(5));

           SVector position = { x, y, z };
           shaiya::CZone::MobGen(CWorld::GetZone(map), mobId, count, &position);

           std::stringstream output_format;
           output_format << "Mob:" << mobId << " respawned at Map:" << map;
           output = output_format.str();
           return 0;   
         
       }
           return 0;
       default:
           break;
       }

       return 1;
   }
}


LPCSTR cmd_mmake = "/mmake";

unsigned u0x4F5BE0 = 0x4F5BE0;//SConsole::AddCommand
void __declspec(naked) naked_0x409459() {
   __asm {

       push 0x0
       push - 0x1
       push 0x6 // param count
       push cmd_mmake
       push 69 // switch case
       mov ecx, esi
       call u0x4F5BE0

       originalcode :
       pop esi
       retn
   }
}

unsigned u0x409498 = 0x409498; // The address to return to for an unsuccessfully handled command.
unsigned u0x40B3D4 = 0x40B3D4; // The address to return to for a successful command.
void __declspec(naked) naked_0x40948F()
{
   __asm
   {
       pushad

       sub ebx,0x4024
       push eax // switch case
       push ebx // input
       call command_manager::execute
       add esp,8

       test eax, eax
       popad
       je write_output

       originalcode :
       cmp eax, 0x44
       ja default_case
       jmp u0x409498

       write_output:
       push command_manager::output
       push edi
       call sprintf
       add esp, 8

       default_case :     
       jmp u0x40B3D4
   }
}

void hook::command_manager()
{
   //CServerApp::InitConsoleCommand
   util::detour((void*)0x409459, naked_0x409459, 5);
   //CServerApp::OnConsoleCommand
   util::detour((void*)0x40948F, naked_0x40948F, 9);
}

Edited by Cups

[HEADING=3]@[mention=18]Lothbrok[/mention] This feature is very practical, but is there a way to set the boss's automatic generation?[/HEADING]

 

[HEADING=3]@[mention=18]Lothbrok[/mention] This feature is very practical, but is there a way to set the boss's automatic generation?[/HEADING]

Create trigger in SQL and use PSMagent.dll to send command to ps_game via SQL

The method is very good. cheers。

Can I add you Discord?

I am willing to pay a fee for you to help me add more admin commands

Create trigger in SQL and use PSMagent.dll to send command to ps_game via SQL

Can you help me add a command for /nmake . it’s make NPC

Can you help me add a command for /nmake . it’s make NPC

you can find the functions inside the source code and let's not fill this article with comments, if u have questions add discord: lothbrok7676

 

static void NpcCreate(CZone* zone/*ecx*/, int npcType, int npcId, SVector* pos/*edi*/);

you can find the functions inside the source code and let's not fill this article with comments, if u have questions add discord: lothbrok7676

yes, ,thankyou lothbrok 。I found this code,

[HEADING=3]Bowie[/HEADING]

is really a genius

  • Author

yes, ,thankyou lothbrok 。I found this code,

[HEADING=3]Bowie[/HEADING]

is really a genius

no. i'm not. 😅

Since you closed the issue on Github, I'm writing here

i see you are adding/removing a skin and something in another custom slot. this library doesn't support those slots, so i'm gonna close this for now.

 

I didn't add a different slot, please don't make a decision without asking, the slot attached is the wing, but this is not the problem, I could do this with the costume in the video, so the problem is valid for the wing, costume and pet, I didn't write to you for a different slot

 

You can corrupt the statistics by changing the armor as in the video and the scary thing is that these statistics are valid and this is a danger for a server that is currently using your code.

  • Author
i told you i could barely see the video. it doesn't matter that my comment was incorrect. i made it clear that i couldn't reproduce the issue when i added the label. do you think i didn't try? i don't know what you are expecting me to do at this point.

Edited by Bowie

i told you i could barely see the video. it doesn't matter that my comment was incorrect. i made it clear that i couldn't reproduce the issue when i added the label. do you think i didn't try? i don't know what you are expecting me to do at this point.

What didn't you see? I don't understand. You could have answered me nicely instead of being rude.

 

Anyway, I have prepared a new video for you, the problem is definitely visible.

but it would be useful to explain the problem again;

I am changing armor and in the meantime I take off and put on a costume and the stat is broken.

 

 

 

https://www.youtube.com/watch?v=LJDx9atEuBQ

  • Author
i wasn't trying to be rude. i had already done what's in the video when i tried to reproduce the issue the first time. i just tried it again and nothing has changed. we're just going in circles at this point. i really don't want to talk about this anymore.

What didn't you see? I don't understand. You could have answered me nicely instead of being rude.

 

Anyway, I have prepared a new video for you, the problem is definitely visible.

but it would be useful to explain the problem again;

I am changing armor and in the meantime I take off and put on a costume and the stat is broken.

 

 

 

https://www.youtube.com/watch?v=LJDx9atEuBQ

 

In the future please try to keep these sorts of conversations in the place where they are most relevant (the Github repository), as it's the most effective place for the conversation due to the nature of code reviews. If you manage the debug and find the issue, consider opening a pull request or fork with the appropriate changes to help assist Bowie with this project. I'd like to remind members of the community that these sorts of open source works are for the benefit of everyone, and we could all do our part to help the process.

In the future please try to keep these sorts of conversations in the place where they are most relevant (the Github repository), as it's the most effective place for the conversation due to the nature of code reviews. If you manage the debug and find the issue, consider opening a pull request or fork with the appropriate changes to help assist Bowie with this project. I'd like to remind members of the community that these sorts of open source works are for the benefit of everyone, and we could all do our part to help the process.

I feel the need to explain myself because I'm being treated like a criminal right now, actually this is not the place for this but I have to write. I couldn't do pull requests or anything like that because it doesn't accept pull requests. I reported an issue on github but he closed it saying he didn't understand the problem and when I couldn't communicate with discord, I had to write here, I wanted to be so supportive because it was for the benefit of the community. but he blocked me now. It doesn't matter, I wish him success in his project, whatever he wants to do is his decision, I didn't want to upset him, but it was not nice of him to approach this way. because he left me no channel to communicate with him and accused me of not writing to him as a private message. I don't think I did anything wrong, I tried to support every project he did until today, but it doesn't matter anymore. Good luck to you

 

-RazoR-

  • Author

i replied to you in private. i guess i should make some things clear in public, regarding the project.

 

i don't want someone to spend hours on a PR and then not have their code merged. asking people not to submit a PR without being invited is my way of being considerate. i don't want to hurt someone that has taken an interest.

 

i'm not good at reviewing code. i have to compile it and check the machine code, especially if there could be a structure misalignment. one byte is all it takes to cause a bug or an access violation. i have to be careful about what i merge.

  • 4 weeks later...

good day

When I use game.exe for Shaiya PT - Patch 0189 (BuildVersion: 0x16032100) Discovering a new feature:

item ability move When in use, there will be a disconnection, and if this feature can be added to SDEV, the effect will be very good

[ATTACH type=full]64[/ATTACH]

Create an account or sign in to comment

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.