Jump to content

TMP4

Contributor
  • Posts

    1112
  • Joined

  • Last visited

  • Days Won

    20
  • Feedback

    100%

Posts posted by TMP4

  1. On 8/26/2021 at 1:36 PM, Abel(Tiger) said:

    For the mall the grid is placed on the db, check ClientManager.cpp bellow this line:

    CGrid grid(5, MAX(1, pi->pSafebox->bSize) * 9);

    screenshot-780.png

     

    screenshot-781.png

     

    Also try this (a common bug in metin2 source):

    In ClientManagerBoot.cpp search:

    sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum());

    And move it before the iterator is initialized like this:

    	m_map_itemTableByVnum.clear();
    	
    	// Now it's here
    	sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum());
    
    	itertype(m_vec_itemTable) it = m_vec_itemTable.begin();
    
    	while (it != m_vec_itemTable.end())
    	{
    		TItemTable * item_table = &(*(it++));
    
    		sys_log(1, "ITEM: #%-5lu %-24s %-24s VAL: %ld %ld %ld %ld %ld %ld WEAR %lu ANTI %lu IMMUNE %lu REFINE %lu REFINE_SET %u MAGIC_PCT %u", 
    				item_table->dwVnum,
    				item_table->szName,
    				item_table->szLocaleName,
    				item_table->alValues[0],
    				item_table->alValues[1],
    				item_table->alValues[2],
    				item_table->alValues[3],
    				item_table->alValues[4],
    				item_table->alValues[5],
    				item_table->dwWearFlags,
    				item_table->dwAntiFlags,
    				item_table->dwImmuneFlag,
    				item_table->dwRefinedVnum,
    				item_table->wRefineSet,
    				item_table->bAlterToMagicItemPct);
    
          	// Also you can insert these values after the sort but because we
            // already looping through the list of items once (for the syslog), it's better to 
          	// move the sort function above (the complexity is half this way)
    		m_map_itemTableByVnum.insert(std::map<DWORD, TItemTable *>::value_type(item_table->dwVnum, item_table));
    	}
    
    	// It was here
    	
    	return true;

     

    After I moved that sort to upper as you suggested, the bug disappeard. 

    Still don't know why it was good in one serverfile, why it wasen't in the other one WITH THE SAME SOURCE, maybe there are some setting, option anywhere that cause this, but your trick clearly solved the bug so I ticked it as the best asnwer, thank you ?

    (I should have try it earlier but as I said I'm helping a friend with this and we did not have time yesterday)

  2. 58 minutes ago, 4peppe said:

    SYSERR: Aug 27 14:39:02 :: QueryLocaleSet: m_stLocale == 0 hi, i have this bug on db syerr...i have tried this 

     with latin1 but don't work. Can you help me?

    That's not a real bug just Ymir (original developer of metin2) back in the time wanted to implement some auto locale set for mysql but did not really finished it and AsyncSql never gets a value there, but until your database have correct collation you're good. 

    If that syserr abuses you then change it to sys_log

        if (0 == m_stLocale.length())
        {
            // sys_err("m_stLocale == 0"); //change
            sys_log(0, "m_stLocale == 0"); //to this...
            return true;
        }

    Your db starting fine isn't it? I did test it with every collation so I hope so.

    • Love 1
    • Love 2
  3. 1 hour ago, Abel(Tiger) said:

    For the mall the grid is placed on the db, check ClientManager.cpp bellow this line:

    CGrid grid(5, MAX(1, pi->pSafebox->bSize) * 9);

    screenshot-780.png

     

    screenshot-781.png

     

    Also try this (a common bug in metin2 source):

    In ClientManagerBoot.cpp search:

    sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum());

    And move it before the iterator is initialized like this:

    	m_map_itemTableByVnum.clear();
    	
    	sort(m_vec_itemTable.begin(), m_vec_itemTable.end(), FCompareVnum());
    
    	itertype(m_vec_itemTable) it = m_vec_itemTable.begin();
    
    	while (it != m_vec_itemTable.end())
    	{
    		TItemTable * item_table = &(*(it++));
    
    		sys_log(1, "ITEM: #%-5lu %-24s %-24s VAL: %ld %ld %ld %ld %ld %ld WEAR %lu ANTI %lu IMMUNE %lu REFINE %lu REFINE_SET %u MAGIC_PCT %u", 
    				item_table->dwVnum,
    				item_table->szName,
    				item_table->szLocaleName,
    				item_table->alValues[0],
    				item_table->alValues[1],
    				item_table->alValues[2],
    				item_table->alValues[3],
    				item_table->alValues[4],
    				item_table->alValues[5],
    				item_table->dwWearFlags,
    				item_table->dwAntiFlags,
    				item_table->dwImmuneFlag,
    				item_table->dwRefinedVnum,
    				item_table->wRefineSet,
    				item_table->bAlterToMagicItemPct);
    
    		m_map_itemTableByVnum.insert(std::map<DWORD, TItemTable *>::value_type(item_table->dwVnum, item_table));
    	}
    	
    	return true;

     

    I have a clue now.

    My reference serverfile have 1 page safebox but my firend's server have enabled 3 page safebox in account.account table (safebox_expire column, it's a default feature btw) for every account, so that's why it's good for me and bad for him with the same source files. 
    "CGrid grid(5, MAX(1, pi->pSafebox->bSize) * 9);"

    I can't test it right now but I'm sure that it is the problem. Thanks for pointing out to that row ?

  4. 9 hours ago, 4peppe said:

    hi I found this bug, in the redthief2_boss2 folder you need to rename specil_attack to special_attack

    Yeah there should be several little bugs like this in a basic metin2 client. But I'll include this change in next release, thanks ?

    Edit: As I see special attack is not used for that mob so that's why this typo didn't bother anyone in the years.

  5. 11 hours ago, Mitachi said:

    I'm not sure, but it seems to me that it shares the same grid as metin2's basic store.
    Check the grids in your src

    spacer.png

    It's 5 and 9, it's a base src. As I said i believe it's not src related problem, is it possible that there are any setting at config files, conf.txt, database or even in client that could cause the grid system / item size (either it is) bug to produce this error?

    Shops, Safebox, Inventory are good tho, it is only the mall. I've never seen a bug like this before.

  6. Hey, currently I'm trying to help a friend with a mall window bug where every item's size is 1 somehow (check picture).
    My first thought it is some fcked up source code, but after we took my serverfile's source and take all items from the window and reinserted new ones
    to item_award the newly insterted items was bugged again to my biggest surprise.

    So it is not source-related I believe. Any idea what can cause such bug? item_award and item table are identical with mine and now the source code too. The items have correct size in item_proto and do behave normal in inventory window.

    My friend with the same source:

    255900Screenshot-1.png

    My with the same source:

    255900Screenshot-2.png

    I can't even guess what can cause such bug, again it's not source-related beleive me or not ?

  7. 12 hours ago, SDlongju2 said:

    too much talk here guys but solution is easy nothing to understand , i tested myself just 

    Step 1 Open config File on core2

    Step 2 Write there on MAP_ALLOW: number : 41

    As you say map 41 is on core 1 but not on core 2 

    Easy and logical:)

    You'll have 2 instance of map1 (41) if you do that. So players in map1 may not see each other. If somebody goes from core1's any map to map1 (41) then he will not see the players who goes from core2's any map to map1 (41).

    • Metin2 Dev 2
  8. 2 hours ago, Near said:

    Hi! I found a visual error in the Spanish language, I attach an image ?.
    https://metin2.download/picture/J7T42Ehx3Z9l661Myc90JZ4RRp8ztp4j/.png

    Solved, In locale_es\locale\es\ui\guild the files were wrong.

    This is the hidden content, please

    Thanks, interesting because I exctracted the locales from the official client from Gameforge's webserver.
    Quickly tested some locales (hu-en-de) but looks like only spanish got this error. Will update the client soon, thank you again.

    Edit: Done

    2021.08.23: - Made LibServerkey compatible with OpenSSL v1.0+, so you can compile it in FreeBSD12+.
                  The changed file is /usr/metin2/src/libserverkey/RSACrypto.cpp.
                - Locale/es/ui/guild files fixed, only spanish locale was wrong.

    The libserverkey change is: https://metin2.dev/board/topic/22635-libserverkey-compatible-with-openssl-v10/ (Thanks arves for the tutorial ? )
    It was needed because some people cleaned the whole project but libserverkey was not in compilable form because of it's deprecated nature.

    VDI is still uploading, give me 30mins, I have 15mb/s upload speed but mega only allows 1mb/s upload now so it takes some time.

    • Metin2 Dev 6
    • Think 1
    • Good 3
    • Love 1
    • Love 8
  9. 10 hours ago, Senect said:

    First of all, thank you, this server files and the video guides are the best thing I've ever saw regarding metin2 in the past 10 years of private servers, easy to set-up and everything worked on 1st try (really hard for Metin2 servers).

    So I have a question now that I've changed the language on both client and server, and checked that everything works fine, I want to make a friend join the server, there's another way other than hamachi (by opening some router ports or something like that) because the last time I used hamachi was on 2012, and I remember it was a pain in the ass to make it works and had some sort of limitation/delay issues, if you can make a small guide (text only too), to convert this local only version to hamachi/online for just me and another friend, I would really appreciate it.

    Thanks again the entire process was smooth and clear, I hope you will keep working on it, and maybe in the next weeks while I play with my friend we can do some testing and report back the bugs we encounter.

    In my video I used home-root setup, if you open the channels-auth ports at your router (check numbers in CONFIG files), your friend can join.
    I'm using a TP-Link router and it's in Nat forwarding -> Virtual servers, and there I can add port numbers and the internal ip and that's it for me.

    But at home-root, you need a "fix": 

    It is because by default it gets your internal ip instead of public ip, so your friend wouldn't connect successfully.
    (This only needed for home root, at "real root" at a vps or a dedicated server hosting, there are no internal ip just public ip, so thats works by default there)

    • Metin2 Dev 1
    • Love 1
  10. 10 minutes ago, marinebun said:

    what do i need to change to use item / mod proto sql instead of txt?

     

    9 minutes ago, backtop said:

    You can change that in the channels config... If I remember it right

    After he installs the No TXT mod ?

    ------------------------

    By the way TXT is much easier, you don't have to do the maths in antiflags and so, you only need to put their name like ANTI_SELL | ANTI_GIVE instead of calculating the number values and summation. But it's on you.

    • Metin2 Dev 1
    • Good 2
  11. 1 hour ago, blanco said:

    Yup, I got the background working, it is pretty much the same as you said. However I don't know how to spawn/position the character on the map

    Oh I see the problem. For now I don't have enough time to make a good release with the character+map render for the charselect window sorry.

    • Love 2
  12. 5 minutes ago, blanco said:

    How can this be done on the select character screen? I can't find out how to make it work ?

    I'm pretty sure it's the same just the bg image name different there to hide.

    Later today i'll upload a default 40k client introselect-introcreate.py with this live background.
    (With comments # INTERACTIVE_LOGIN so you can see where the codes are)

    • Good 2
  13. 8 minutes ago, Nirray said:

     

    A slightly different idea than mine that I wrote a long time ago, but the effect is the same ? 
    Remember to use along with this:
    https://metin2.dev/board/topic/22783-fix-skybox-cloud-clipping/

    Otherwise, sky clouds clipping will be visible when logging in aaaand very annoying ? 

     

     

    To fix that, you need to do same thing what "Item Shop" window does - disable mouse scroll when window is opened.

    Damn that's next level ? Amazing, epic.

    • Love 1
  14. 5 minutes ago, FBI said:

    My dear, nice system i like it!

    There is one "bug". You can zoom in & zoom out on login screen.

    Thank you ;D It is a default behavior of Metin2 but I may try to lock the zoom / mouse wheel in the future. (Or enable right click to rotate)
    Anyway at least users can see it's a live map, not a picture ?

    • Good 1
    • Love 1
  15. 2 hours ago, ReFresh said:

    @TMP4 And this problem? (it's disabling shadows, of course it's some error):

      Reveal hidden contents
    0819 18:32:01149 :: CPythonBackground::GetFarClip m_eViewDistanceNum=0

     

     

    I'm on it, I need some time.

    Edit: Fixed the shadow bug. background.Destroy() was missing.

    Edit2: Fixed that harmless syserr too. I edited def LoadMap(self):

    If there are any more problem please let me know, I will try to fix it ASAP.

    • Metin2 Dev 1
    • Good 3
  16. 7 minutes ago, ReFresh said:

    @TMP4

    intrologin.py:

      Reveal hidden contents
    https://pastebin.com/vaDRun2X

     

    loginwindow.py:

      Reveal hidden contents
    https://pastebin.com/E00UDVrP

     

    bg1 is missing from your loginwindow.py, you only have bg2.
    So just simly not use bg1 in intrologin.py, remove self.GetChild("bg1").Hide() from my code.

    • Good 1
    • Love 1
  17. 31 minutes ago, ReFresh said:

    @TMP4 Tested and got an error:

      Reveal hidden contents
    0819 17:45:01302 :: Traceback (most recent call last):
    
    0819 17:45:01302 ::   File "uiPhaseCurtain.py", line 59, in OnUpdate
    
    0819 17:45:01302 ::   File "networkModule.py", line 147, in __ChangePhaseWindow
    
    0819 17:45:01302 ::   File "introLogin.py", line 306, in Open
    
    0819 17:45:01302 ::   File "introLogin.py", line 346, in LoadMap
    
    0819 17:45:01302 ::   File "ui.py", line 2802, in GetChild
    
    0819 17:45:01302 :: KeyError
    0819 17:45:01302 :: : 
    0819 17:45:01302 :: 'bg1'
    0819 17:45:01302 :: 
    
    0819 17:45:01302 :: CPythonBackground::GetFarClip m_eViewDistanceNum=0

     

     

    In a default client bg1 is the name of the background/serverlist image. That's what we hide in this release because it would cover the rendered map. self.GetChild("bg1").Hide()

    Your client probably have other name for the image or something. Post your intrologin.py and locale/xy/ui/loginwindow.py and I'll help.

  18. With this guide you can render map(s) to your login screen. Some server back in 2012 used this kinda login (DaRealFreak) and I found it pretty cool, so I did this tutorial maybe people will use it again. At def LoadMap(self): there is a list called environments where I set 17 location for you. You can edit/extend it as you wish. The client choose a random location from that list. Somebody will surely comment that it's make the client opening slower. Yes it does, but as you can see in the video that's minimal. Also if you use a client with intro video logo then it doesn't matter because that's longer than it's 1-1,5 second loading time. But if you think it's not acceptable then either optimize it somehow or stay with image background ?

    This is the hidden content, please
    You can disable the environmental background by editing INTERACTIVE_LOGIN = 1 at the top to INTERACTIVE_LOGIN = 0.
    Here's a basic intrologin.py with this environmental background if you want to compare: 
    This is the hidden content, please
     (
    This is the hidden content, please
    )

    Original idea by DaRealFreak in 2012.

    Sincerly,
    TMP4

    • Metin2 Dev 238
    • kekw 2
    • Eyes 3
    • Dislove 5
    • Angry 2
    • Not Good 1
    • Sad 1
    • Think 1
    • Confused 1
    • Scream 3
    • Lmao 2
    • Good 71
    • Love 16
    • Love 158
×
×
  • 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.