Summary of existing issues:
x86 debug build, built March 20th 8:47am. Using ROF or UF clients. Cleric mercs chain cast bulwark of vie on themselves with a level 66 j2 healer merc for example, this happens on a number of buffs for healer mercs. Strange part is after i died and delveled to 65 the merc would still chain cast buff but it wouldnt say bulwark of vie, just say casting a spell, surrounded by bright white aura... Tank mercs dont rest regen at all, ever. If you suspend your merc and delvel(like if you died in a zone, had someone rezz you in zone, and tried to bring merc back) you cant unsuspend, dismiss, or do anything with pet. Sometimes zoning brings it back, sometimes not. Seeing lots and lots of chars with 1-8 mercs for same charid with the multiples suspended. i saw one instance of a single char having 14 different mercs with all suspended but 1. All in all, lots of improvements, thank you for the hard work. |
I'll have to do some more testing. I haven't seen the chain casting of any of the vie spells, at least at 65, but there shouldn't be much difference between the two.
Unless I'm wrong, you need to sit to rest regen, correct? I guess I could have them sit, but that would look a little strange, the tank merc sitting in between pulls. I still haven't fixed the delevel bug. Yes, it will be the same between suspending and dying and deleveling. I will try to get it done by the end of the weekend. I know i fixed the multi-save issue a while back, so I'm not sure why that came back. I know there have been a lot of changes in the last week or so, so maybe something broke again. Or it's happening after the merc gets bugged. Right now, mercs are being suspended when you die, so that could be the cause. I'll look into it. |
Update-
Everyone on server that i could talk to had healer mercs chain buffing. i personally saw them(mercs) chain buffing bulwark of vie on themselves, and after i jumped my level up they started chain casting symbols on themselves. The point being is they only seem to chain cast buffs on self. Perhaps that helps. I have disabled them from buffing for now till it gets squared away. Tank and melee mercs sitting is fairly important early on because people use the tank merc to duo with and since most arent healers, rest regen in between fights is important to them. Its quicker in the early levels to let a merc tank plow through stuff rather than try to tank something and have a merc healing you. To add more detail on the multisave. I am not sure what triggers it for sure yet, seems to involve suspending/unsuspending. In database there are no DUPLICATE mercs that are exactly the same name. There are just multiple mercs with different names for ONE pc. |
Quote:
As for the AI, I will take a look at that next. edit: AI issue seems to be maybe related to having wrong merc spells data. The buffs they cast need to be set to type buff, or 8. Should work in its current form heh. |
Secrets, is there any way you could split out the merc stuff into a separate pull request? I was looking through it last night and saw a bunch of other stuff I don't feel comfortable messing with. I'd like to be able to apply just those changes to my local machine and test them with some other changes I've made. If not, I can just apply each change manually, but I'd like to try out the pull requesy stuff. Still learning git and coming up with a more efficient process.
|
Also, I guess we can add a check for melee mercs to sit if there's no healer and/or below a certain level.
|
Quote:
I'm not exactly sure but I think you can just clone my repository and test the changes that way. Basically, the things I fixed are the following: -Made emulator structure for two packets (OP_MercenaryData and OP_MercenaryMerchantResponse) static instead of creating it dynamically twice -Fixed a memory leak in the AI code. -Fixed a memory leak related to groups. In their current form, groups are leaking memory because they are never assigned a group ID in the unsuspend command. -Fixed a few issues with merging groups with mercenaries in them. -Fixed an issue where group IDs were not being handed out and leaking memory in OP_GroupDisband and OP_GroupFollow The two changes that were not related to mercs are: -Fixed a crash issue in the RoF encoder -Fixed a crash issue related to calling NPC functions after the deconstructor for NPC was called. |
Question-
Double checking merc_spell_list_entries What does the slot number do exactly? |
Quote:
|
Slot is how the spells are ordered. So, when buffing, healers will loop through their spells, starting slot 1, and going up from there. I have plans to use it to help identify single and group spells. I.E. Virtue is slot 1- I want it cast first. I would also check for a buff in slot 1 that was a group spell, and assume it was Hand of Virtue. I would then cast it if a group spell was prefered. That code isn't in yet, but the spells should be ordered by slot so the mercs will cycle through their spells. CastercDPS mercs also use it to cycle through all of their nukes once they are all in. That way, specific nukes higher in the spell list will be cast more often.
I'll check it out more tonight, secrets. It was just hard to see the merc specific changes- there seemed to be a lot of unrelated changes in the pull request. Maybe I'm just looking at it wrong. |
Thank you for the information, that is helpful
|
Quote:
|
Update on chain casting bug..
I happened to log my 66 necro, who did not have a pet out at the time. I noticed the merc did NOT chain cast buffs... strange i thought because every other character had so far. Then i summoned a pet with no buffs... J2 healer merc level 66 starts chain casting virtue on HIMSELF not the pet. Been doing it for 10 minutes now. Once is get rid of the pet the merc healer stops trying to buff himself. Even more interesting is i suspended the healer merc, and summoned pet to do some tests.. after i was done with the pet i dismissed the PET, and tried to unsuspend the merc, couldnt do it, nothing happened. After i zoned the merc was out and responsive, but when i picked dismiss, it dismissed him but said " an error created your mercenary" or something very close. So it would seem it has something to do with pets. I never noticed before because my server is very pet centric(everyone gets one) Well i made a new char, put him at level 66, hired a j2 healer merc, who castst hand of virt, aura of temp, then chain casts bulwark of vie. There was never a pet cast or present during this process.. im lost. |
Figured out way to create another merc for same char.
Created level 66 j2 healer merc, suspended him while hes trying to chain cast, then try and unsuspend...., nothing happens, i pick dismiss it says it was dismissed even thou it wasnt unsuspended. You get "an error created your mercenary" when you dismiss it. I then bought a new j2 tank merc in same zone, which it gave me... boom, now it shows i have both mercs in database. |
Well, I've figured out the chain casting issues. And it involves pets. I like your bug reports. They usually send me to the right place to look.
I have Secret's changes merged into mine, so it might take a little while to test everything. I'll try to get it comitted tonight, however. |
Buffing should be fixed.
Secret's fixes are in, so hopefully they will take care of the other issues you are having. If not, please let us know. Thanks! |
Thank you very much for putting all that in, compiling now, will test this morning.
|
Chain cast bug seems to be gone, thanks.
I have not been able to create duplicate mercs yet, not very many on yet. I have not had any crashes yet, will take some time to see if this happens. Thanks again, those were showstoppers for me. |
To clarify, I didn't commit his fixes for two crashes you listed in your other thread, the one for emotes and the other. I just got the merc ones in, so you might still get those. I just didn't have much time last night and wanted to get those couple of things fixed.
|
Ok thanks for info.
I found a few sql errors you may want to correct... From 2013_03_14_Merc_Spells.sql Code:
((SELECT merc_spell_list_id FROM merc_spell_lists WHERE class_id = 2 AND proficiency_id = 1), (SELECT id FROM spells_new WHERE name = 'Ethereal Remedy' ORDER BY id DESC LIMIT 1), 8, 0, 59, 60, 6, 0 ), Pious Remedy has max level of 255?? Pious elixir has maxlevel of 255. Aura of Devotion has max level of 255. All those i THINK should be alot lower max level?? Just trying to pitch in. |
Yeah, Ethereal Remedy should be spell type should be 2 for heal, and slot 1.
The others with their max levels: Pious Remedy 70 Pious Elixir 71 Aura of Devotion 71 Code:
UPDATE merc_spell_list_entries Good catch. |
is there a way besides cost to restrict merc purchases? I'd prefer players to not have access to a Tier V merc at level 1. Are there any rules in place for this, either flagging Qglobals or level?
|
Update-
After i pulled down secrets source around 11:30am CST and built that i hopped into the game ( UCS seems broken after that, says mail key is not right for world.exe). Bug where develeing after death would cause merc to become unresponsive is gone. The only way i can temporarily get it to become unresponsive is if i die, lost level, and rezz in same zone, and even then after i zone the merc comes back just fine. Chain casting bug is gone. Well see on the zone crash stuff. Pretty much every possible thing i could think of, cant break mercs right now. We will see if players can. |
Quote:
It will get put in eventually, but if you want to play around with it, check for where it sends the available merc templates to the client in MercenaryMerchantResponse or whatever. |
Things are getting better. Trying secrets update to fix the one crash in last 20 hours ive had.
Here is a summary of bugs and issues: Bug - If you die and delevel/rezz in same zone merc unresponsive. Issue - Healer mercs do not cure themselves or anyone else of anything? Issue - Healer mercs do not cast healdots, tried enabling it and they cast them but the spells dont heal for anything... weird.. Issue - Tank Mercs dont rest regen Thanks for all the work! |
Great info Bad_capn. I will play with it.
In the meantime, If i wanted to remove (I'd much rather just disable them) journeyman mercs (without completely breaking the merc tables) what's the easiest way to do that? Should I: 1) Wipe the hired merc table, delete the mercs from the merchant template entries where (and i'm not sure how to do in in SQL -- MERC ID matches with name like '%journeyman%' from the merc_npc_types table) so they should be unpurchasable? 2) Just delete * where name like '%journeyman%' from merc_npc_types table -- but will that break the merc merchants? 3) Is there a way to implement a cost PER MERC? -- I would love to set the journeyman mercs to cost a crazy amount of plat, that would solve everything rather nicely. Thanks again for any help you guys can provide |
There is a function that returns the cost of the merc based on a simple formula I came up with that is pretty close up to level 65 or so. You should be able to add more based on the proficiency if you wanted to.
You could also do it in sql. I can't test right now, but removing the templates from the merchants would be the best of your options, so you could keep most of the data there in case you wanted it later. Another option is client version, which is in merc_templates. Set that to a very high number so it won't show up for any client (this restriction works so you don't get unknown dbstring errors for invalid races or classes depending on your client). I'll try to come up with a script when I get a chance. |
After yesterdays build with secrets latest patch, the crashes stopped, so i thought things were good until i noticed mercs with no owners standing around in hub area today. I checked DB and lots and lots of multiple mercs per PC in merc database.
I am cleaning out the DB and rebuilding source and will let you know results. |
Running latest git pull, x86 build, seems to happen on either UF and ROF clients.
Considering ive only had 6 people over last couple hours, and already i have 2 instances of multiple mercs per PC. No crashes that i can find. |
Still havent figured what causes it. It might be related to grouping because these mercs below are run by a guy who multiboxes/groups...
Anyhow demonstrating the "leftovers" http://s13.postimg.org/tdhjqxq6v/mercs.jpg |
Quote:
|
Ok, sounds good.
|
Quote:
|
Thank you much, that should ease the mana strain on them.
|
Some additional feedback; i'm not sure if this is exclusive to me or those of us using mercs but; has anyone noticed with the latest build and mercs that grouping seems off? If I'm two boxing, the invitee doesn't see the other's merc in the group but the inviter sees the group leader's merc within the group.
If i revert a few builds back the issue isn't there. Disbanding, suspending etc. doesn't seem to fix the problem. |
Possible bug
Is that GetSTR() supposed to be there in merc.cpp
Code:
int16 Merc::CalcAGI() { |
One bug and a few things i dont understand.
I buy a level 50 J2 tank merc, has base stats like DB using #showstats. If i buff him with "Swift like the wind" spell number 172 which to my knowledge has no stat or resist buffs in it, then the merc has around 20 added to str,dex,40 to sta, 20 to agi, and resists are bumped up 60? When you suspend and restore the merc MOST of the time the stats return back to normal. Picture is below demonstrating me buying the merc, #showstats, buffing-showstats, suspending and bringing him back - showstats. I totally don't understand this. Why do the mercs have so much attack? The values in the database don't match up with stats shown in game, and the ATK stats in the database are SKY high. If i am understanding the code in attack.cpp right below then its looking for merc ATK which doesn't seem to be the same as in the database(which is even higher) Is it using CalcATK() from merc.cpp?? If so does then CalcATK also adds strength and skill to come up with its number?? If CalcATK does that then isnt Str and Offense added twice when it hits the code below?? I am trying pretty hard to balance things for my server, and the ground keeps shifting under my feet every time i solve one problem. Any information is apprecaited. Thank you. Code:
if(attacker->IsClient()) http://s23.postimg.org/dbtw2hniz/mercstats.jpg |
I've been out and busy the last 2 weeks, so I'm going to try and get back into this this weekend and check out some of the issues you've pointed out.
I'd have to look into the buffs. Not sure what's going on there. Attack and AC are kind of confusing and how they are calculated and displayed are different between clients, npc, bots, mercs, and pretty much everything else. Merc base ATK and AC may be higher than what clients are used to because they have little to no way to improve them. No equipment upgrades, no AAs, etc. Only buffs can be used to increase them. They may still be a little high, as I just guessed when I created them, trying to get them close to high end client values at that level. If you have a specific example of what one should be, I can adjust them accordingly. #Showstats shows different values for Bots as well, but I'd have to look into it again, as it's been a while since I tried to figure it out. I do remember ATK values being maybe half what they should have shown for bots. Edit: Looks like that is being added twice. I'll get that removed. |
I have figured out the buffs issue, I believe. I'll see if I can get it in this weekend.
|
Thank you.
I agree the attack code is confusiing. Since you asked for a specific example ill give you one with the level 50 scenario above. The example below ASSUMES i know what the code is doing. I am going to leave ATK values out of it because im not sure what is being calced here. Mob is level 50 Froglok Dar Knight from sebilis who has an AC of 429 in DB. Level 50 Merc attack the Froglok. Merc has str of 267, and warrior for that level has offense of 210. Running that through formuyla listed above WIHTOUT the ATK added onto it gives you 463 for attack RATING. Froglok is an NPC so the NPCACfactor rule is 2.25 by default. Code:
else if(IsNPC()) You can see the problem is that the attack rating is already over 2 times the AC to begin with. Now if you add (im working from memory) several hundred or thousand ATK once or twice you can see that the attack rating to AC ratio is someplace from 3x to 20x. To be fair , you are remarkably close on your AC settings for mercs tanking NPCs. |
All times are GMT -4. The time now is 04:45 AM. |
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.