Jump to content

Jonathan

Advanced members
  • Content Count

    25
  • Joined

  • Last visited

  • Days Won

    6

Jonathan last won the day on March 10

Jonathan had the most liked content!

Community Reputation

35 Neutral

2 Followers

About Jonathan

  • Rank
    Cabin Boy

Recent Profile Visitors

1,094 profile views
  1. Just checked and it is a DNS issue, thank you!
  2. When is the website going live? Right now it redirects to the hosting "domain parked" page.
  3. The easiest way to do this is to click on the icons, copy the link that it directs you to, and then search for that link within your files. It should lead you to where you can set your own links. Do you find anything when you search for the links within your files? If not, which files are you using?
  4. Am not seeing the same issue, can see the video fine. Maybe there is a silent country restriction? Video mirror for resolution of 557 x 360: https://mega.nz/file/AAkywD4a#EcUqDRfgRJ3RemOfPAXkkMuqOVaCLw9aLRnYt3tBJUo Video mirror for 1280 x 828: https://mega.nz/file/MMMEFKoS#P0dv0aFirFZWxOQz8ZSrtysQ_yneKFzQcoydhjndV9M If you ever run into the same problem again, I just used streamabledl (https://streamabledl.com/) and I doubt there are any silent restrictions downloading videos through that site. It is possible I'm wrong and there are, but it could at least be worth a try.
  5. What is the vision for this server? Like what style of server is your team aspiring to make?
  6. I would encourage you to use the search function at the top right of each forum page. A quick search yielded the following result:
  7. What have you tried so far? Where did you get stuck?
  8. If you are just trying to determine the parameter so that you can use a startgame batch file... Open the game using whatever launcher, then open a command line prompt. Enter “WMIC /OUTPUT:ProcessList.txt PROCESS get Caption,Commandline,Processid”. View command line options used to open each open program inside ProcessList.txt - specifically, look for the command line options used to open Game.exe. Then write your batch file using those command line options instead of startgame.
  9. @barselon8 It is interesting math - I could be entirely wrong, but I would guess the reason for dividing by 1000 is to avoid using floats / doubles until absolutely necessary. This will have a positive impact on evaluating final values accurately, and also - more importantly - will reduce computational time. I'd imagine the performance differences were far more noticeable back when this game was first published. Looking at "GetChaAttr()" in the source, all values returned are whole numbers (either ints or longs) which further supports this idea. With regards to where the calculations are for "ATTR_ITEMC_MXHP"... "GetChaAttr() is in the source at "Source/Server/GameServer/src/Expand.h". This just points us to "nAttrVal = (long)pCCha->getAttr(sAttrIndex);". If we then follow the trail to "Source/Common/Common/include/ChaAttr.h" this points us to: inline LONG64 CChaAttr::GetAttr(long lNo) {T_B if (lNo >= ATTR_MAX_NUM) return -1; return m_lAttribute[lNo]; T_E} which begs the question of where "m_lAttribute" gets set. Navigating to "Source/Common/Common/src/ChaAttr.cpp" we find that the values in "m_lAttribute" are set based on the record retrieved via "CChaRecord *pCChaRecord = GetChaRecordInfo(lID);". In "Source/Common/Common/include/CharacterRecord.h" we find another inline function: inline CChaRecord* GetChaRecordInfo( int nTypeId ) { return (CChaRecord*)CChaRecordSet::I()->GetRawDataInfo(nTypeID); } and so on... that is the end of my sleuthing on this, but that should be fairly close to actually finding where the value gets set. Good luck!
  10. @barselon8 The only variable there is the "a", which is the character's role. The rest are all function calls to functions you can find within "functions.lua". e.g. function MxhpIa(a) --LuaPrint("Obtain character attribute mxhp_ia") local mxhpia=GetChaAttr(a, ATTR_ITEMC_MXHP)/ATTR_RADIX --[[取mxhp道具百分比]]-- return mxhpia end function MxhpIb(a) --LuaPrint("Obtain character attribute mshp_ib") local mxhpib=GetChaAttr(a, ATTR_ITEMV_MXHP) --[[取mxhp道具常数]]-- return mxhpib end In these functions, the first variable in the call to "GetCharAttr()" is again the character's role, and the second variable in those calls is the attribute being retrieved as defined in "AttrType.lua". The "ATTR_RADIX" variable is the attribute coefficient as defined in "variable.lua".
  11. No problem @barselon8. Which variables specifically are you referring to?
  12. @barselon8 If I am understanding correctly, you want to investigate the functions "Mxhp_final()", "Mxsp_final()", "Mnatk_final()", etc. in "functions.lua". e.g. function Mxhp_final(a) local mxhp_final=(BSMxhp(a) * MxhpIa(a) + MxhpIb(a) ) * math.max(0, MxhpSa(a)) + MxhpSb(a) --[[取当时实际mxhp]]-- --LG("chaattr_set", " BSMxhp = " , BSMxhp(a) , "MxhpIa = " , MxhpIa(a) , " MxhpIb = " , MxhpIb(a) , "MxhpSa = " , MxhpSa(a) , "MxhpSb = ", MxhpSb(a) , "\n" ) --LG("chaattr_set", "mxhp_final = ", mxhp_final , "\n" ) return mxhp_final end These functions are where the final values are calculated, which account for any additional stats provided by items.
  13. No problem at all @kyleflow! Your understanding is correct. The default "Check_CG_HechengBS()" per the 1.38 files posted by V3ct0r at is function Check_CG_HechengBS ( Item_Lv , Item_Type , Sklv ) local a = 0 local b = 0 Item_Lv = Item_Lv - 1 if Item_Type == 49 then a = math.max ( 0 , math.min ( 1 , ( 1 - Item_Lv * 0.10 + Sklv * 0.10 ) ) ) b = Percentage_Random ( a ) if Item_Lv < 3 then b = 1 end return b elseif Item_Type == 50 then a = math.max ( 0 , math.min ( 1 , ( 1 - Item_Lv * 0.05 + Sklv * 0.15 ) ) ) b = Percentage_Random ( a ) return b else LG( "Hecheng_BS","probability check determine item type is not a gem" ) return 0 end end So for this we would just need to work backwards. When "ItemType" is 49, for 100% success rate the calculation "1 - Item_Lv * 0.10 + Sklv * 0.10" needs to evaluate to 1, and when the "ItemType" is 50, for 100% success rate the calculation "1 - Item_Lv * 0.05 + Sklv * 0.15" needs to evaluate to 1. In both scenarios you just need to - as you correctly said - manipulate "STATE_HCGLJB" which will in turn manipulate "Sklv" in each of these calculations.
  14. Looking at the "Composition Catalyst" or "Red Combining Fruit" that ordinarily increase combining success, their item effect calls the function "ItemUse_HSDZG()" in "ItemEffect.lua". function ItemUse_HSDZG ( role , Item ) local statelv = 2 local statetime = 60 local Cha_Boat = 0 Cha_Boat = GetCtrlBoat ( role ) -- SystemNotice( role , Cha_Boat ) if Cha_Boat == nil then AddState( role , role , STATE_HCGLJB , statelv , statetime ) else SystemNotice( role , "Cannot use while sailing" ) UseItemFailed ( role ) return end end This function adds the state "STATE_HCGLJB" with a set state level ("statelv") - by default the state level is 2. The function to combine two gems is "begin_unite_item()" in "forge.lua". In this function, we call back on that same state to check the state level when calculating the success rate. function begin_unite_item (...) -- ... -- -- snip -- local Sklv = 1 local StateLv = GetChaStateLv ( role , STATE_HCGLJB ) Sklv = Sklv + StateLv local b = Check_CG_HechengBS ( Item2_Lv , ItemType2 , Sklv ) if b == 0 then i = RemoveChaItem ( role , ItemID2 , 1 , 2 , BagItem2 , 2 , 1 , 0) --移除宝石 if i == 0 then LG( "Hecheng_BS" , "Delete item failed" ) end local cha_name = GetChaDefaultName ( role ) LG( "JingLian_ShiBai" , "Player"..cha_name.."Gem combining failed" ) SystemNotice( role , "Very sorry, combining has failed. Gem has vanished…") return 2 end local cha_name = GetChaDefaultName ( role ) LG( "JingLian_ShiBai" , "Player"..cha_name.."Gem combining successful" ) return 1 end Inside "begin_unite_item()" the function you have posted, "Check_CG_HechengBS()", is called to determine whether or not combining was successful. To calculate this, we pass in "Sklv" which is calculated as "1 + STATE_HCGLJB state level", so by default the value passed in is 3. Originally "Check_CG_HechengBS()" used a function of "Sklv" to determine whether or not combining was successful. In the function as you have posted it, "Sklv" goes completely unused. I will assume you are intentionally not using the original function, and will not refer to specific modifications of the original function. If you want to make combining 100% successful when the user has used a "Composition Catalyst" or "Red Combining Fruit", there are two places you could do it. Either a) Inside "begin_unite_item()", instead of calculating "b" you could first check the "Sklv", and if the user has used the appropriate fruit you could simply assume success already. This way we only use the function that includes randomness when no catalyst/fruit has been used. e.g. function begin_unite_item (...) -- ... -- -- snip -- local Sklv = 1 local StateLv = GetChaStateLv ( role , STATE_HCGLJB ) Sklv = Sklv + StateLv if Sklv == 1 then local b = Check_CG_HechengBS ( Item2_Lv , ItemType2 , Sklv ) if b == 0 then i = RemoveChaItem ( role , ItemID2 , 1 , 2 , BagItem2 , 2 , 1 , 0) --移除宝石 if i == 0 then LG( "Hecheng_BS" , "Delete item failed" ) end local cha_name = GetChaDefaultName ( role ) LG( "JingLian_ShiBai" , "Player"..cha_name.."Gem combining failed" ) SystemNotice( role , "Very sorry, combining has failed. Gem has vanished…") return 2 end end local cha_name = GetChaDefaultName ( role ) LG( "JingLian_ShiBai" , "Player"..cha_name.."Gem combining successful" ) return 1 end or b) Inside "Check_CG_HechengBS()" you change the function to actually make the calculation of "a" some function of "Sklv" again. That modification / function could be very simple. e.g. working from the function as it is in your post (and slightly refactoring it for the sake of simplicity) function Check_CG_HechengBS ( Item_Lv , Item_Type , Sklv ) Item_Lv = Item_Lv - 1 if Item_Type == 49 or Item_Type == 50 then local a local b if Sklv == 3 then a = 1 elseif Item_Lv < 3 then a = 1 elseif Item_Lv == 3 then a = 0.9 elseif Item_Lv == 4 then a = 0.8 elseif Item_Lv == 5 then a = 0.7 elseif Item_Lv == 6 then a = 0.6 elseif Item_Lv == 7 then a = 0.5 elseif Item_Lv == 8 then a = 0.4 elseif Item_Lv == 9 then a = 0.3 end b = Percentage_Random ( a ) return b else LG( "Hecheng_BS","probability check determine item type is not a gem" ) return 0 end end Whether or not that specific modification works depends whether of the rest of the functions involved have been modified on your server too, so try to follow the information and don't just copy and paste my solution. If you want to create a completely new fruit to make combining 100% successful, you will need to make the item call a different function than "ItemUse_HSDZG()" which in turn changes the state level of "STATE_HCGLJB" to a different state level, and then again modify how that state level gets used in either "begin_unite_item()" or "Check_CG_HechengBS()". As alluded to above though, your current iteration of "Check_CG_HechengBS()" means that neither the "Composition Catalyst" nor the "Red Combining Fruit" hold any effect on the combining success rate, so creating an entirely new catalyst / fruit may be unnecessary. Let me know if this explanation makes sense or if you have any further questions.
  15. Since your files to decrypt are on the desktop, you won't need to run the bat file as administrator. However, the two dashes in front of decrypt_texture() mean that the line is commented out, so will not execute. There is a large block of commands at the of the file, and if you aren't going to put your method call there then you may want to check that nothing else is being called by accident. To have your method run, remove those two dashes; then, running the bat file normally (not as administrator) should be fine. In any case! My mistake for not catching this nuance running as admin - when you run a bat file as admin the current directory defaults to system32, as in your screenshot. To remedy this, you will need to: 1. Open a command prompt as administrator; 2. Change to the appropriate directory 3. Run the batch file commands manually So, assuming your decompiler is located on the Desktop: 1. Open a command prompt as administrator 2. Run the following commands: i) cd "C:\Users\OldWise\Desktop\top-decompiler (1)" ii) luajit decompiler.lua Let me know how it goes, regardless whether you decide to do it by running as administrator or not.
×
×
  • Create New...