Jump to content
  • 0

Custom ("Offline") Vending (Not extended vending)


Recently I heard of the new "offline vending" in official servers



And I've been wondering how to achieve that, either it be on a "as close as possible" basis where I  have the vending to work with inventory items and then on succesfully creating the vending the items would be removed from player's inventory and he could manage it from the server website (to cancel/change price/etc). Once cancelled or sold get the stuff back by RodEx, like in the video.

From what I can see in the video, it looks like they create a fake cart for the player and then add the player's items to that cart and display the normal vending screen with a limited number of 4 items, since that's the max items you can send via RodEx. After proceeding with the vending, it allows you to aim and then creates a copy of your player with a vending (lol ?)

Any directions on how to accomplish this would be much appreciated. So far I can create a vending using an atcommand I've created by cloning the contents of 

void clif_openvendingreq(struct map_session_data* sd, int num)

and setting a state variable to bypass the vending control which checks if the vending was opened by using the skill

Edited by Slim
  • Like 1
Link to comment
Share on other sites

6 answers to this question

Recommended Posts

  • 0
1 hour ago, Gladius said:

I think it should be possible to make a "gambiarra" with the auction system.
It's just a theory, I have no idea how to create.

It looks like it's not included in newer clients anymore

Link to comment
Share on other sites

  • 0

Actually this is pretty cool, I saw it in official too. But haven't seen anyone created this in rathena.

Link to comment
Share on other sites

  • 0

I have started the work on this but didn't have any time nor interest to finish but I could get a proof of concept working. The concept is somewhat basic but I took a different approach than the officials, where they create a clone from your character and open the stall using that clone. I used the existing system for auctions and hooked an external web app to list the auctions. That external app would be able to buy the items, notifying the running server and then the server would send mails to both the seller and the buyer with their items.

The external app talk via REST to a NodeJS/Express server which connects to rAthena via TCP streams and exchange raw packets. It seems a bit complicated, but once you get the hang of how packets work you'll be fine.

On the rAthena side I've hooked some methods and packets to open/close auctions and to send mails.


Node/Express server can be found here https://github.com/Danil0v3s/react.cp

rAthena modifications can be found here https://github.com/Danil0v3s/broriginal/pull/11

And the external app I've created to use as a launcher using Electron.JS can be found here https://github.com/Danil0v3s/broriginal-launcher


None of these wouldn't be possible without the help from Norminator, Nitrous, Zell and many others. If you have any questions regarding any of these, I'll keep an eye on this thread. And please, bear in mind that I haven't created any of these to be used by anyone else but me, so you won't find any comments or anything explaining anything and some solutions are completely hammered just to work

Edited by Danilov3s
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.