The Bytecode Club
Log inJoin the club
Video Game Reverse Engineering

๐Ÿ˜› Dropping trophies not properly. [Solved]

Started by TheBeardWoman ยท Jan 5, 2015

4 replies70,145 views
Jan 5, 2015#1

Log:

2015-01-05 02:23:10 : ~~~~Welcome to COC Bot Pre-Alpha v005.3.1!~~~~
2015-01-05 02:23:10 : Executable running on X64 system
2015-01-05 02:23:10 : Bot is starting...
2015-01-05 02:23:15 : Training Troops...
2015-01-05 02:23:37 : Training Troops Complete
2015-01-05 02:23:38 : ~~~Waiting for full army~~~
2015-01-05 02:23:50 : Training Troops...
2015-01-05 02:24:07 : Training Troops Complete
2015-01-05 02:24:07 : Full Army
2015-01-05 02:24:08 : Trophy Count : 944
2015-01-05 02:24:08 : Dropping Trophies
2015-01-05 02:24:16 : Bot has stopped

I set "Dropping trophies" to 1300 but he's dropping trophies even though mine are at 944.
Is it a bug?
Did I do something wrong?

Thanks in advance.

Jan 5, 2015#2

@TheBeardWoman That problem can be fixed if you replace the DropTrophy() function (Line 1305):

Func DropTrophy()
	Local $TrophyCount = getOther($BSpos[0] + 50, $BSpos[1] + 74, "Trophy")
	While Number($TrophyCount) > Number($itxtMaxTrophy)
		getBSPos()
		$TrophyCount = getOther($BSpos[0] + 50, $BSpos[1] + 74, "Trophy")
		SetLog("Trophy Count : " & $TrophyCount)
		If Number($TrophyCount) > Number($itxtMaxTrophy) Then
			SetLog("Dropping Trophies")
			getBSPos()
			If _Sleep(2000) Or $RunState = False Then ExitLoop

			ZoomOut()
			PrepareSearch()

			While Not checkNextButton()
				If _Sleep(500) Or $RunState = False Then ExitLoop
			WEnd

			Click(34, 310) ;Drop one troop

			If _Sleep(1000) Or $RunState = False Then ExitLoop

			ReturnHome(False, False) ;Return home no screenshot
		Else
			SetLog("Trophy Drop Complete")
		EndIf
	WEnd
EndFunc   ;==>DropTrophy
Jan 19, 2015#3

what will i change sir?

Jan 19, 2015#4

pardon sir i dont get it with your explnation ๐Ÿ™

Jan 19, 2015#5

So you edit the au3 file and then you find "Func DropTrophy()" and you replace it with the code above. Select the entire function from "Func DropTrophy()" to "End Func" and then replace it with the code I gave above.

Got something to add?

Log in to post a reply.

Join the conversation