Quote:
Originally Posted by Paristôn
Sorry brothers i know i got too much here but, i need your help
i have tried to reach tq attack but i got alot of errors, also i'm confused i cann't get the trusted attack.
so if it's not annoying .. please give me the nearest conquer online attack because i dun like 100.000 attack and 50.000 of defense .. that make things looks completely bad.
I preferre you give me the total codes because i got alot of errors as i said before .. for example, sometimes i hit with 0's like "MortalWound" skill for Assassin.
and also, i got some errors like .. if i'am a prince and faced a king .. i can ff/ss with only 4k to 6k "his hp is 41k lol" .. (I'm MAXED chi) with P-Attack = 11k P-Attack
that's hard to be explained but please try to get the idea, and help me if u can.
NOTE 1 : an +12 -7 2socs / full chi / jianghu is maxed account = 46k attack.
NOTE 2 : Please stop saying .. "Don't open online server and u dunno Programming logic" .. that became too boring -_-, that's why they opened this section .. it's only for help
Thanks
|
Can you imagine the logic to calculate Attack? I am not sure, some peoples think it's different for each skill and build >1000 Lines of codes re-writing it in every subtype.
Meele skills use the Meele attack base multiplied by the skill power.
Magic skills does have another calculation, of course, but if the Magic attacks does have many subtypes, you don't need to re-write it on each one.
I saw on some sources, Monk Attack, Trojan Attack, Assassin Attack... C'mon, it's stupid, They all share the same attack formula, just a few things change and i'm pretty sure it isn't because of the class.
This is not 100% accurate, but i will help you with part of the formula.
1. Build a Class to check if the map allows PK and if the target is attackable.
2. Calculate the Damage your character can deal, min and max, dont include Talismans. Get Dragon Gems and Build your own Rules.
3. Get a Random number out of those 2 values.
4. If Attacker BP >= Attacked BP. Continue to Step 5.
4a. Get Attacker BT and Attacked Counter, If Difference > 100, don't change anything, Else, Calculate if the user will activate BT. If activate, Continue to Step 5, else, Damage / 2.
5. So here i know if the User will deal his total damage or not, as we know, with lower bp my damage gets reduced by 50%, break wont make that change, don't forget to send the effect. Then, get Attacker Critical and Attacked Immunity. If Difference > 100, Attacker Damage * 1.5, if <= 0 Step 6, else Check if the user will deal the Critical Damage and send the effect with Attacker Damage * 1.5.
6. If the Attacker has Lucky Time, check if he will Deal 2x Damage.
7. If the Attacked has Lucky Time, check if he will absorve the damage and return 1.
8. I am working on a web site and wont describe it totally. Calculate defense and the last step is add the +Final P Damage and Reduce if the Target uses a Tower... Well. I forgot to mention some other things like Dodge and etc, but good luck. Build your own code and you will know how to deal with the errors.
Like i have on my Codes commented.
"This code is protected by international laws and by god laws. After all, just god knows how this shit works. If you don't understand dont alter anything."
Note 1 = Don't calculate Phoenix n Dragon Gems.
Note 2 = Help isn't equal to "Give ready to use codes", isn't equal to "I need to reply all your questions as you wish" or even "I need help with this error (Failed to connect to MySQL Server)".
Done