Jump to content

Recommended Posts

  • Developer

Download Center

This is the hidden content, please

This is the hidden content, please

The tutorial contains an already configured json file!

Q.
 What is trivially the difference?
A. Here's an example:

Spoiler


Old fishing.txt:

spacer.png


New fishing.json:
spacer.png

---

spacer.png


I tested it, here is some evidence + a dip into the past ?

spacer.png

After installing, you can do /fish_simul to test if it works properly.

Non-Critical issue
The strings for fish names in Korean are broken at the time of reading
I could have done something about it but I noticed that korean names are mostly used by fish_simul
(A gm command used to test fishing), and since we are not Korean
I didn't bother much to fix it, rather I did a cleanup to my fishing.cpp/.h which I can post below if you want.

   I thank @ martysama0134 for the idea.

Edited by Mitachi
Core X - External 2 Internal
  • Metin2 Dev 131
  • Think 1
  • Good 15
  • muscle 1
  • Love 6
  • Love 51

Villains are not born, they are made.
Join

Link to comment
https://metin2.dev/topic/30811-better-json-fishing-load-renewal/
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

  • Active+ Member

You can check if ifstream is open instead of using the filesystem library (which comes from C++17):

std::ifstream file(LocaleService_GetBasePath() + "/fishing.json");

if (!file.is_open()
	return;

// ...

Also you should remove #include <fmt/core.h> to avoid compilation errors.

Edited by Thorek
  • Facepalm 1
  • Love 1
  • Developer
7 hours ago, Thorek said:

You can check if ifstream is open instead of using the filesystem library (which comes from C++17):

std::ifstream file(LocaleService_GetBasePath() + "/fishing.json");

if (!file.is_open()
	return;

// ...

Also you should remove #include <fmt/core.h> to avoid compilation errors.

no

  • Facepalm 2
  • Think 1
  • Good 1

Villains are not born, they are made.
Join

Don't use any images from : imgur, turkmmop, freakgamers, inforge, hizliresim... Or your content will be deleted without notice...
Use : https://metin2.download/media/add/

Please use https://metin2.download/ when uploading files smaller than 100MB, otherwise the approval will take longer due to manual upload.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.