Page 6 of 16

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 12:58 am
by ellisdee
Hmm. I've gone as far as to
-remove all addons except d303 and ingamfuntions
-destroy hidden Runes of Magic folder in my docs
-Default all game settings
-Install fresh d303
-remove Model folder

Tomorrow I will blow this system away, and start completely from the ground up. Hopefully somewhere in that the issue is resolved for me, though it
wouldn't leave much in the way of pin pointing the initial error or flaw.

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 1:04 am
by ellisdee
Well thats what i get for not hitting refresh before i make a post

Rock5 you nailed it.
At the commandline try


Code:
print(memoryReadStringPtr(getProc(), addresses.partyLeader_address,0))
This returned my party leads name which is 16 characters long.

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 1:13 am
by lisa
I thought we added something to deal with names 16 characters, I guess we didn't do it for the partleadername function.

I do remember this being a pain in the butt a while ago and took ages to work out why some had issues.

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 1:28 am
by lisa
also once the party leader has had a name of 16 characters it stays using the address even if current leader has 4 characters.

testing this atm.

Code: Select all

function getPartyLeaderName()
	local name
	if memoryReadInt(getProc(), addresses.partyLeader_address + 4) == 0 then
		name = memoryReadStringPtr(getProc(), addresses.partyLeader_address,0)
	else	
		name = memoryReadString(getProc(), addresses.partyLeader_address)
	end
	if( bot.ClientLanguage == "RU" ) then
		name = utf82oem_russian(name)
	else
		name = utf8ToAscii_umlauts(name)
	end
	return name
end

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 3:45 am
by rock5
Except how do you deal with names that are 4 characters long. Your code will assume it's an address.

Found, partyLeader_address + 0x14 changes from 0x0F to 0x1F if it has changed to an address.

Code: Select all

   if memoryReadInt(getProc(), addresses.partyLeader_address + 0x14) == 0x1F then
      name = memoryReadStringPtr(getProc(), addresses.partyLeader_address,0)
   else   
      name = memoryReadString(getProc(), addresses.partyLeader_address)
   end
Although I don't know what 0x1F means so it possible it could have other values. Maybe it's a half byte value.

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 4:17 am
by lisa
you know this conversation is feeling like a serious deja vu, even down to the 0x1F and 0x0F.

We deffinately discussed this before.

was the same thing in partymembername function, we ended up using this

Code: Select all

	if memoryReadRepeat("byte", getProc(), memberAddress + 0x1C) == 31 then
		memberAddress = memoryReadRepeat("uint", getProc(), memberAddress + 8 )
		local name = memoryReadString(getProc(), memberAddress)
			if( bot.ClientLanguage == "RU" ) then
				name = utf82oem_russian(name);
			else
				name = utf8ToAscii_umlauts(name);   -- only convert umlauts
			end
		return name
	else
		local name = memoryReadString(getProc(), memberAddress + 8)
			if( bot.ClientLanguage == "RU" ) then
				name = utf82oem_russian(name);
			else
				name = utf8ToAscii_umlauts(name);   -- only convert umlauts
			end
		return name
	end
the 0x1C byte value. 31 is 0x1F

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 4:26 am
by lisa
so looking like this

Code: Select all

function getPartyLeaderName()
	local name
	if memoryReadByte(getProc(), addresses.partyLeader_address + 0x14) == 0x1F then
		name = memoryReadStringPtr(getProc(), addresses.partyLeader_address,0)
	else   
		name = memoryReadString(getProc(), addresses.partyLeader_address)
	end
	if( bot.ClientLanguage == "RU" ) then
		name = utf82oem_russian(name);
	else
		name = utf8ToAscii_umlauts(name);   -- only convert umlauts
	end  
	return name
end

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 6:32 am
by rock5
Ok, copied to my version.

Re: Party Bot (questions/answers)

Posted: Sun Feb 03, 2013 11:28 pm
by ellisdee
Updated to 748

-Tests pass and return long character name normally.
-Party members mount/dismount with Partylead
-Partylead setting target (1) raid Icon on mobs
-party members attack and heal as they are designated to.

I seen an addition for names with Umlauts, I've been trying to reach another player
who has them in their character name. They described similar issues as me, Though I've not
been able to reach them today to suggest the update.

Thank you both very much! Fantastic work :ugeek:

Re: Party Bot (questions/answers)

Posted: Sun Feb 10, 2013 5:45 am
by Alleexx
I'm pretty sure I've seen the answer to this somewhere but I can't find it anymore so I'm asking here. I want to do dod with a healer and a dps but I can't use the partyhealer script as it would just get stuck all the time and not work the way it should.
How do I make the healer heal my dps even if it's running a normal waypoint?

Re: Party Bot (questions/answers)

Posted: Sun Feb 10, 2013 6:12 am
by lisa
Normal bot won't heal party members, so you would need to run it with partyhealer or maybe Rock's RBassist, which do similar things.

what do you mean get's stuck all the time?

If you mean it doesn't enter portals then check the third post this topic for your answer.
http://www.solarstrike.net/phpBB3/viewt ... 579#p44579

Re: Party Bot (questions/answers)

Posted: Sun Feb 10, 2013 11:26 pm
by abron1
i have the same problem with the portal it targets the portal then mm window says that is didn't find a portal then errors everything esle works fine

is there a command for the bot not to loot? because if you use it to help you heal in a instance even tho its on no follow it will run up and loot and argo mobs and try to fight back lol. its funny when it happens but then it dies and i have to make it run back.. so i guess what i am asking is can you make it so if its on no follow it won't loot until you set it to follow again?

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 1:58 am
by lisa
abron1 wrote:i have the same problem with the portal it targets the portal then mm window says that is didn't find a portal then errors everything esle works fine

is there a command for the bot not to loot? because if you use it to help you heal in a instance even tho its on no follow it will run up and loot and argo mobs and try to fight back lol. its funny when it happens but then it dies and i have to make it run back.. so i guess what i am asking is can you make it so if its on no follow it won't loot until you set it to follow again?
it loots according to profile options, so you just need to change the profile options for it.
Again post 3 of this topic
http://www.solarstrike.net/phpBB3/viewt ... 579#p44579

type this in party chat, then set it to true when you want it to loot again.

Code: Select all

code"changeProfileOption("LOOT", false)"

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 2:04 am
by abron1

Code: Select all

code"GoThroughPortal()"
i use that code for the party bot to go though but it errors and because it says it can't find the portal.

next question: is there a way for the party bot to heal warden pets because for some reason mine won't heal the pet at all...

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 3:23 am
by lisa
abron1 wrote:but it errors and because it says it can't find the portal.
Have you got the latest version of rocks userfunction?
abron1 wrote:next question: is there a way for the party bot to heal warden pets because for some reason mine won't heal the pet at all...
Little more complicated to add in, at the moment it doesn't go through all objects around you to find who is in the party, it knows the names of party members and uses that. In order to heal warden pet's we would need to go through all objects which would put a bit more strain on the bot.

Or do you mean for wardens to heal their own pet's? because that wouldn't be part of partyhealer obviously as wardens arn't healers.

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 3:39 am
by abron1
yeah i mean for the healer to target warden pet and heal it but its ok ill figure something out or just resummon. and i do have the latest version of rocks function but ill delete it and re download and see what happens

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 3:53 am
by lisa
have you got the elven prayer skill in your wardens profile?
If you have it in your wardens profile it will use it anytime your pet's HP is below 70%.

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 4:12 am
by lisa
ok there was a mistake in the party.lua, I used a ' when I shouldn't have.


Use this 1.

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 6:02 am
by abron1
ok i got your new version to late to test need to sleep before babies wake up

Re: Party Bot (questions/answers)

Posted: Mon Feb 11, 2013 7:45 am
by rock5
Lisa you didn't mention there were other changes in this file that needed to be committed so it got committed without them. The difference between this file and the committed one in 750 is just this bit of code

Code: Select all

	if mob.MaxHP > (player.MaxHP * settings.profile.options.AUTO_ELITE_FACTOR) then
		-- check if preCodeOnElite event is used in profile
		if( type(settings.profile.events.preCodeOnElite) == "function" ) then
			releaseKeys();
			_arg1 = mob
			local status,err = pcall(settings.profile.events.preCodeOnElite);
			if( status == false ) then
				local msg = sprintf(language[188], err);
				error(msg);
			end
		end
	end	
Sorry.