OK to ask for exploit/Scripting help here...

02/14/2019 19:55 DerMoench14#46
For me it still works.
How do you call the Function?
02/14/2019 20:13 maril15#47
Quote:
Originally Posted by DerMoench14 View Post
For me it still works.
How do you call the Function?
HasEffect($SkillID) like HasEffect(1043) (for Dash)
02/14/2019 20:49 DerMoench14#48
Dunno who wrote Func HasEffect() ...
If you just want the Function to return a boolean you can do it this way:

Code:
;Pass skill ID, returns True if you're under the effect
Func HasEffect($Effect)
	If GetEffectTimeRemaining($Effect) > 0 Then
		Return True
	Else
		Return False
	EndIf
EndFunc   ;==>HasEffect
02/25/2019 16:53 diguano#49
hello, I would like to know the coding so that the bot and the scripts are in the background at the start please? because each bot takes me 30% of the processor ... thank you cordially
02/25/2019 17:41 Borega#50
Code:
Func ToggleRendering()
	$RenderingEnabled = Not $RenderingEnabled
	If $RenderingEnabled Then
		EnableRendering()
		WinSetState(GetWindowHandle(), "", [MENTION=330060]Sw_[/MENTION]SHOW)
	Else
		DisableRendering()
		WinSetState(GetWindowHandle(), "", [MENTION=330060]Sw_[/MENTION]HIDE)
		ClearMemory()
	EndIf
EndFunc   ;==>ToggleRendering
02/25/2019 18:25 NiliyaFlamme#51
Hallo,

habe volgene Probleme
1. ich möchte mein bot überprüfen lassen wv Gold er hat und wenn er zb mehr wie 80k hat soll ers einlagern
2. er soll überprüfen wv kurz pkt er hat und und wenn er zb mehr wie 60k hat soll er spenden gehen .

also meine frage iss wie schreib ich das im Script rein das es klapp hab schon einiges prob aber geht ned xD -.-...^^


Hello,

I have lots of problems
1. I would like to have my bot checked how many gold he has and if he has more like 80k, for example, he should stock up
2. he should check how many Kurz pts he has and if he has more like 60k he should donate.
**
So my question iss how do I write in the script
02/26/2019 07:46 ForgottenRelic#52
[Only registered and activated users can see links. Click Here To Register...]


I currently have this file in which it is an exe....

Simple Plagueborn Chest runner, was working great until the last inventory update.
Just tried running it right now, get to one open chest, searches for lockpicks then comes up error that ran out of lockpicks.

Kinda stuck here because since this is an exe file and no script files, i cant locate the inventory/ LP issue to fix it.
02/26/2019 11:13 Borega#53
Quote:
Originally Posted by NiliyaFlamme View Post
Hallo,

habe volgene Probleme
1. ich möchte mein bot überprüfen lassen wv Gold er hat und wenn er zb mehr wie 80k hat soll ers einlagern
2. er soll überprüfen wv kurz pkt er hat und und wenn er zb mehr wie 60k hat soll er spenden gehen .

also meine frage iss wie schreib ich das im Script rein das es klapp hab schon einiges prob aber geht ned xD -.-...^^


Hello,

I have lots of problems
1. I would like to have my bot checked how many gold he has and if he has more like 80k, for example, he should stock up
2. he should check how many Kurz pts he has and if he has more like 60k he should donate.
**
So my question iss how do I write in the script
Look at the functions: Getgoldcharacter(), DepositGold(), DonateFaction() and be sure to update your headers using the updatescript.
03/01/2019 21:12 NiliyaFlamme#54
Hello ,
would need help with my bot, he should when I finished the quest and give up
since the quest donor but in motion he should really give it then when the quest is delivered, he goes to the npc and tries to give away
ask for help as I write the best



Hallo ,
bräuchte Hilfe bei mein bot , er soll wenn ich die quest fertig hab abgeben und aufgeben
da der quest geber aber in Bewegung is soll er wirklich ers dann aufgeben wenn die quest abgegeben is, bis her geht er den npc hinterher und versucht abzugeben
bitte um Hilfe wie ich das am besten schreib


UPDATE I GOT it
03/04/2019 20:33 NiliyaFlamme#55
hay can someone help me that my bot use hero skills i kow the fun useheroskill(9 but it dont work -.-
03/05/2019 03:26 RiflemanX#56
Quote:
Originally Posted by NiliyaFlamme View Post
hay can someone help me that my bot use hero skills i kow the fun useheroskill(9 but it dont work -.-
There are only 8 skills. If you are trying to use 9 then I doubt you can make that work.

If you are trying to have Hero 9 use a skill and he is not in your party then I dont think that will work out well either.

The function shows that you need more information when you use it.


Code:
;~ Description: Order a hero to use a skill.
Func UseHeroSkill($aHero, $aSkillSlot, $aTarget = 0)
	Local $lTargetID

	If IsDllStruct($aTarget) = 0 Then
		$lTargetID = ConvertID($aTarget)
	Else
		$lTargetID = DllStructGetData($aTarget, 'ID')
	EndIf

	DllStructSetData($mUseHeroSkill, 2, GetHeroID($aHero))
	DllStructSetData($mUseHeroSkill, 3, $lTargetID)
	DllStructSetData($mUseHeroSkill, 4, $aSkillSlot - 1)
	Enqueue($mUseHeroSkillPtr, 16)
EndFunc   ;==>UseHeroSkill
03/05/2019 12:59 NiliyaFlamme#57
i know he cant use hero skill 9 i mean useheroskill() xD

what should I write that uses my hero 1 skill 1?

i know my hero cant use skill 9 ..^^ i mean useheroskill()
what should I write that uses my hero1, skill 1 (its a spirit)
03/05/2019 13:15 RiflemanX#58
Quote:
Originally Posted by NiliyaFlamme View Post
i know he cant use hero skill 9 i mean useheroskill() xD

what should I write that uses my hero 1 skill 1?
Simple:

Code:
UseHeroSkill(1, 1)
Or

Code:
UseHeroSkill(1, 1, -2)
03/05/2019 13:57 NiliyaFlamme#59
dont work my hero still do nothing xDD

Func Start()
Sleep(2000)
MoveTo(15382.00, 6565.00)
Sleep(2500)
WaitMapLoading($Map_Drazach_Thicket,2000)
Sleep(2000)
FlagAll($aX, $aY);==>CommandAll(7550.48, 16992.20)
MoveTo(14993.40, 8953.10)
Sleep(35000)
UseHeroSkill(1,1)
UseHeroSkill(3,1)
Sleep(7000)
UseHeroSkill(1,2)
Sleep(7000)
UseHeroSkill(1,3)
UseHeroSkill(2,5)
UseHeroSkill(7,1)
Sleep(1000)
UseHeroSkill(2,4)
UseHeroSkill(7,2)
TakeQuest()
EndFunc^

this is what i try but my heros do nothing idk why if someone know what is fail pls help :)
03/06/2019 04:03 RiflemanX#60
Quote:
Originally Posted by NiliyaFlamme View Post
dont work my hero still do nothing xDD

Func Start()
Sleep(2000)
MoveTo(15382.00, 6565.00)
Sleep(2500)
WaitMapLoading($Map_Drazach_Thicket,2000)
Sleep(2000)
FlagAll($aX, $aY);==>CommandAll(7550.48, 16992.20)
MoveTo(14993.40, 8953.10)
Sleep(35000)
UseHeroSkill(1,1)
UseHeroSkill(3,1)
Sleep(7000)
UseHeroSkill(1,2)
Sleep(7000)
UseHeroSkill(1,3)
UseHeroSkill(2,5)
UseHeroSkill(7,1)
Sleep(1000)
UseHeroSkill(2,4)
UseHeroSkill(7,2)
TakeQuest()
EndFunc^

this is what i try but my heros do nothing idk why if someone know what is fail pls help :)
I am confused beyond words. It may be helpful to see the gwa2 you are working with as it may have errors in the function. Please upload your script and I will look at it.

Also, when you zone, it is best to use Move() instead of MoveTo()
When you try to zone with MoveTo your bot will keep trying to reach the destination when the map screen is loading and this can cause Disconnect. Use MoveTo() to get closer to the portal and then use Move() to step through.

You also add sleep after MapLoading() but MapLoading already has sleep inside the function so no need to add more sleep unless you have lag issues in which case you should use something like the function PingSleep or simply write out the ping in the function.

When you have lag and timing is important:

Code:
Sleep(GetPing() + 2000)
This will detect your lag or ping rate and add it to your sleep time

Another way is to write a simple function:

Code:
PingSleep(2000)


Func PingSleep($msExtra = 0)
	$ping = GetPing()
	Sleep($ping + $msExtra)
EndFunc
As for your problem with your heroes not casting try also:

Code:
UseHeroSkill(1, 1, -2)
UseHeroSkill

if you are using gwa2 and there is no modifications to the function it should work as you have above using simply UseHeroSkill(1,1) or UseHeroSkill(1, 1, -2) however if you are attacking something you may want to make sure to target an enemy so all attack at the same time for effective spike.

Here is an example for the Raptor Farming script. In this script Hayda is moved to just outside the cave and casts buffs on the Warrior or Necro farmer.


Code:
Func MoveToBaseOfCave()
	If GetMapID() <> $MAP_ID_RIVEN Then Return

	If GetIsDead(-2) Then Return
	Out("Moving to cave")
	Move(-21975, -7372)
	RndSleep(Random(1800, 2200))
	UseHeroSkill(1, 3)
	Moveto(-21213, -8134)
	UseHeroSkill(1, 4, -2)
	Sleep(1500)
	;Rndsleep(1250)
	UseHeroSkill(1, 5, -2)
	Rndsleep(Random(20, 50))
	UseHeroSkill(1, 6)
	Rndsleep(Random(20, 50))
	UseHeroSkill(1, 7)
	Rndsleep(Random(20, 50))
	UseHeroSkill(1, 8, -2)
	Move(-20613, -9529, 40)
EndFunc