Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 04/15/19 in all areas

  1. M2 Download Center Download Here ( Internal ) Download Here ( GitHub ) Builtin Debug Formatter A simple debug class which is used for output the messages for debugging. The class doesn't need to be called, we've added the functions into built-in functions. The purpose was to ease the work of developers. What's the difference between them? Using the new method: TraceError("str", 1, 4.0, (31, 22), [100, 200], True) Tracef("str", 1, 4.0, (31, 22), [100, 200], True) LogBox("str", 1, 4.0, (31, 22), [100, 200], True) sys_err("str", 1, 4.0, (31, 22), [100, 200], True) # No import needed, is a built-in function, you can call it everywhere. # The function sys_err or TraceError doing the same thing. # Allow to pass unlimited argument-lines, no data types check, can be everything you want: <int, float, string, tuple, list, boolean>. Using the old method: import dbg dbg.TraceError("just_one_string_allowed") dbg.Tracef("just_one_string_allowed") dbg.LogBox("just_one_string_allowed") # Need to import the module dbg every time in every file where you want to use it. # Allow to pass just one argument-line which need to be string, otherwise nothing happen. Built-In-Functions: Built in or inbuilt function are that type of functions which are already defined or created in a program or in programming framework. User don’t need to create these type of functions. User or developer can directly use built in function by only call it. This function is built into an application and can it can be accessed by end-users with simply call it. How-It-Works: TraceError(args) - function prints the given arguments to the text stream file syserr.txt Tracef(args) - function prints the given arguments to the console window (screen) while executable is compiled in a debug mode. LogBox(args) - function prints the given arguments to the dialog box that contains a system icon, a set of buttons, and a brief application-specific message, such as status or error information. sys_err(args) - same as TraceError. How-To-Call-Ex : sys_err('warning', 'error', 'unknown') << 415 17:8:1130 :: warning << 415 17:8:1130 :: error << 415 17:8:1130 :: unknown sys_err(100/2==50, 'set value to {}'.format(25)) << 415 17:6:1083 :: True << 415 17:6:1083 :: set value to 25 sys_err([45, 100], (200, 1500, 32), 42.8, 500, "donald-trump", False) << 415 17:8:1094 :: [45, 100] << 415 17:8:1094 :: (200, 1500, 32) << 415 17:8:1094 :: 42.8 << 415 17:8:1094 :: 500 << 415 17:8:1094 :: donald-trump << 415 17:8:1094 :: False sys_err("what-you-want") << 415 17:8:1072 :: what-you-want GitHub repository: [Hidden Content]
    6 points
  2. If you purchased the system contact the owner for help. We don't provide support for leaked systems. #closed Links removed
    3 points
  3. Even if he wanted to change the bonus type, you still need how calculation works, you'll add Att Monster instead of Max HP and at Perfect Master, the value will be 1.862? So he still need the calculations, before doing this, also for change the type of bonus isn't so easy, at least you need to know some things. The current party bonuses are saved just as a point-value, not as a real bonus, the real bonus is calculated from another parts. PARTY_ROLE_SKILL_MASTER > POINT_PARTY_SKILL_MASTER_BONUS case POINT_MAX_SP: { SetPoint(type, GetPoint(type) + amount); const int iRealPointSP = GetRealPoint(POINT_MAX_SP); int iAddSP = MIN(800, iRealPointSP * GetPoint(POINT_MAX_SP_PCT) / 100); iAddSP += GetPoint(POINT_MAX_SP); // Add SP to current value by party skill bonus iAddSP += GetPoint(POINT_PARTY_SKILL_MASTER_BONUS); SetMaxSP(iRealPointSP + iAddSP); val = GetMaxSP(); } break; POINT_PARTY_ATTACKER_BONUS POINT_PARTY_TANKER_BONUS POINT_PARTY_BUFFER_BONUS POINT_PARTY_SKILL_MASTER_BONUS POINT_PARTY_HASTE_BONUS POINT_PARTY_DEFENDER_BONUS So if you want to change the bonuses, you've to rewrite all the calculations from those functions (remove the lines += GetPoint(..), and make them static, depends of you how and where, you can add it inside party.cpp after ComputePoints of each bonus like. // Set as melee ch->PointChange(POINT_ATTBONUS_MONSTER, ch->GetPoint(POINT_PARTY_BUFFER_BONUS));
    2 points
  4. Srcs/Server/game/src/party.cpp float k = (float) ch->GetSkillPowerByLevel( MIN(SKILL_MAX_LEVEL, m_iLeadership ) ) / 100.0f; // PARTY_ROLE_ATTACKER int iBonus = (int) (10 + 60 * k); // PARTY_ROLE_TANKER int iBonus = (int) (50 + 1450 * k); // PARTY_ROLE_BUFFER int iBonus = (int) (5 + 45 * k); // PARTY_ROLE_SKILL_MASTER int iBonus = (int) (25 + 600 * k); // PARTY_ROLE_HASTE int iBonus = (int) (1+5*k); // PARTY_ROLE_DEFENDER int iBonus = (int) (5+30*k); float k = (float) ch->GetSkillPowerByLevel( MIN(SKILL_MAX_LEVEL, m_iLeadership ) ) / 100.0f; m_iLeadership = Leader skill ship skill level which is increased by (book vnum: 50301, 50302, 50303) int CHARACTER::GetSkillPowerByLevel(int level, bool bMob) const { return CTableBySkill::instance().GetSkillPowerByLevelFromType(GetJob(), GetSkillGroup(), MINMAX(0, level, SKILL_MAX_LEVEL), bMob); } int CTableBySkill::GetSkillPowerByLevelFromType(int job, int skillgroup, int skilllevel, bool bMob) const { if (bMob) return m_aiSkillPowerByLevelFromType[0][skilllevel]; if (job >= JOB_MAX_NUM || skillgroup == 0) return 0; int idx = (job * 2) + (skillgroup - 1); return m_aiSkillPowerByLevelFromType[idx][skilllevel]; } Let's take a example, a warrior, skill group 1. idx = 0 * 2 + 1 - 1 = 0 skilllevel = m_iLeadership m_iLeadership = 40 (Skill Perfect Master) // 0 5 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 50 52 54 56 58 60 63 66 69 72 82 85 88 91 94 98 102 106 110 115 125 125 125 125 125 m_aiSkillPowerByLevelFromType[0][40] = 125 PARTY_ROLE_DEFENDER: (5+30*k) k = 125 / 100 = 1.25 iBonus = 5 + 30 * 1.25 = 42.5 (converted to integer will be 42) Output from skill P: // PARTY_ROLE_ATTACKER - Set as attacker 10 + 60 * (125 / 100) = 85 // PARTY_ROLE_TANKER - Set as berserker 1 + 5 * (125 / 100) = 7.25 = 7 // PARTY_ROLE_BUFFER - Set as melee 50 + 1450 * (125 / 100) = 1862.5 = 1862 // PARTY_ROLE_SKILL_MASTER - Set as blocker 5 + 45 * (125 / 100) = 61.25 = 61 // PARTY_ROLE_HASTE - Set as defender 5 + 30 * (125 / 100) = 42.5 = 42 // PARTY_ROLE_DEFENDER - Set as wizzard 25 + 600 * (125 / 100) = 775 Is a fast explanation, i hope you understand it.
    2 points
  5. M2 Download Center Download Here ( Internal ) Hi there devs, Probably the most of us know the problem when an image contains alpha/fully transparent parts but you can't click trough them and it would be very necessary to do so. This problem is very common with the taskbars, for example with the ilumina taskbar (you know when it looks like you are clicking the ground, but the image is still there but that part is transparent). Video: How to: EterPythonLib\PythonWindow.h EterPythonLib\PythonWindowManagerModule.cpp EterPythonLib\PythonWindow.cpp EterLib\GrpImageTexture.cpp EterLib\GrpImageInstance.h EterLib\GrpImageInstance.cpp By default it won't check the alpha value, so it means that you have to add manually the "alpha_sensitive" flag to the preferred windows/objects (also note that its only effective with an expandedImageBox object and it has some interference with the "float" flag (if both added to the same object)). For the usage check the video. If you have any question, remark, or anything that you like to ask or suggest, feel free to post it here, or send it in PM. Have a nice day, ~masodikbela
    1 point
  6. You should replace the condition in function OnUpdate: #if 0 != self.targetName: if self.targetName and self.chatLine:
    1 point
  7. Thanks it was ## in inventroywindow!: )
    1 point
  8. Maybe some wrong in UserInterface/GameType.h or in GameLib/ItemData.h or in python part(uiscript/inventorywindow), These are just some ideas, but surely the problem is there.
    1 point
  9. Weed's idea for sex verification is very good, like this:
    1 point
  10. I think job 4 = lycan
    1 point
  11. Thanks to @ProfessorEnte for reports. 2019-04-12 02:31:18 Friday - 170 additions and 50 deletions. Fixed unique items based on the real time. Fixed unstackable items. Fixed if item count overflow occured, then set it to maximum. Added support for books. (check skill types, unknown skill), skill vnum need to be saved into socket0, (4=Aura of the Sword < player.skill_proto), if the skill vnum is unknown, there will be a random book based on pc races, excluded skills PASSIVE, GUILD, SUPPORT. Added a to-do for ITEM_BLEND, check if apply_type exists in bonuses, check if apply_value/apply_duration is equal with grades (1/2/3/4/5) from settings, blend.txt Added auto query. # Random book INSERT INTO player.item_award(`login`, `vnum`, `count`, `mall`) VALUES ('account', 50300, 1, 1); # Specific book by skill vnum INSERT INTO player.item_award(`login`, `vnum`, `count`, `socket0`, `mall`) VALUES ('account', 50300, 1, 4, 1);
    1 point
  12. The old effects of the skills were still in the Gameforge servers when I started playing. They changed it a few months later in 2008.
    1 point
  13. Open db/ClientManagerBoot.cpp bool CClientManager::InitializeLandTable() { using namespace building; under this add CDBManager::instance().DirectQuery( "update land " "INNER JOIN guild ON land.guild_id = guild.id " "INNER JOIN player ON guild.`master` = player.id " "set guild_id=0 " "where guild_id > 0 and " "DATE_SUB(NOW(),INTERVAL 21 DAY) > last_play; " ); CDBManager::instance().DirectQuery( "DELETE object " "FROM object " "INNER JOIN land ON land.id = object.land_id " "WHERE land.guild_id=0; " ); Extracted from Inception source.
    1 point
  14. Hello everybody, since I've heard that a lot of servers (and even the most recent vanilla source release) have no fix for this hack I decided to release this. It's not too big, but I really would like to make it visible for everybody. I highly dislike hacks in every form and I'll gladly develop such fixes. So, the fix is quite easy. It's a bug from metin2. They decided to add a check if the target is too far away to be attacked and yeah, that works. Targets only receive damage once they're within range. But the problem is that modern moblock tools do that a different way. They send attack packets to every mob in the near surrounding which triggers aggr towards the player. You may ask: Why does it trigger aggr and let the mobs move to the player? Well, as mentioned, the source has a fix for that - but it's implemented too late. 1. Open char_battle.cpp and search for this function: CHARACTER::Attack First you may notice that there's literally no check for distance. The distance check is implemented in battle.cpp in the function battle_melee_attack. That's fine and we don't need to modify anything about this. 2. If you scroll down you'll see the following lines: pkVictim->SetSyncOwner(this); if (pkVictim->CanBeginFight()) pkVictim->BeginFight(this); Noticed something? Yeah, the check is - as mentioned before - in the function battle_melee_attack. The problem is, that these lines are executed before the check happens. So hackers will be visible in logfiles (syslog should spam distance errors) but they're still free to hack like they want to. 3. Move the lines below the battle type segment So, how do we fix this? We'd simply move it down below the battle type functions. So you'd move it just before the line "if (iRet == BATTLE_DAMAGE || iRet == BATTLE_DEAD)". But still that won't be enough since these lines would still be executed. We don't want them to be executed. So we wrap a condition around it. 4. modify these lines so they look like this: if(iRet != BATTLE_NONE) { pkVictim->SetSyncOwner(this); if (pkVictim->CanBeginFight()) pkVictim->BeginFight(this); } If we take a look on the battle type functions we'll notice that they return the BATTLE_NONE if something goes wrong - for example the distance is invalid. 5. you're done! The fix pretty much solves this issue. If you still know hacks that work feel free to write in this topic, I'll gladly share solutions once I've developed them. Enjoy!
    1 point
  15. 0 points
  16. 0 points
×
×
  • 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.