Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Faster deployment speed
#27
(02-05-2015, 10:20 PM)dinobot Wrote:  Lol... I didn't mentioned anything about atkAlgorithmTH()?
Anyway it is algorithm_AllTroops

Hehehe! maybe misunderstanding because in the link you agree what other forumer said in the code he / she post ..

Code:
Func algorithm_AllTroops() ;Attack Algorithm for all existing troops
$King = -1
$Queen = -1
$CC = -1
$Barb = -1
$Arch = -1
   For $i = 0 To 8
If $atkTroops[$i][0] = $eBarbarian Then
$Barb = $i
ElseIf $atkTroops[$i][0] = $eArcher Then
$Arch = $i
ElseIf $atkTroops[$i][0] = $eCastle Then
$CC = $i
ElseIf $atkTroops[$i][0] = $eKing Then
$King = $i
ElseIf $atkTroops[$i][0] = $eQueen Then
$Queen = $i
EndIf
Next

If _Sleep(2000) Then Return
   Local $nbSides = 0
Switch $deploySettings
Case 0 ;Single sides ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SetLog("~Attacking in a single side...")
$nbSides = 1
Case 1 ;Two sides ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SetLog("~Attacking in two sides...")
$nbSides = 2
Case 2 ;Three sides ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SetLog("~Attacking in three sides...")
$nbSides = 3
Case 3 ;Two sides ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SetLog("~Attacking in all sides...")
$nbSides = 4
EndSwitch
if ($nbSides = 0) Then Return
If _Sleep(1000) Then Return

; ================================================================================
; ========= Here is coded the main attack strategy ===============================
; ========= Feel free to experiment something else ===============================
; ================================================================================
algorithmTH()
if LauchTroop($eGiant, $nbSides, 1, 1, 1) Then
If _Sleep(1000) Then Return
  EndIf
if LauchTroop($eBarbarian, $nbSides, 1, 2) Then
If _Sleep(1) Then Return
  EndIf
if LauchTroop($eArcher, $nbSides, 1, 2) Then
If _Sleep(1) Then Return
  EndIf
If _Sleep(1) Then Return
If LauchTroop($eBarbarian, $nbSides, 2, 2) Then
If _Sleep(1) Then Return
EndIf
if LauchTroop($eWallbreaker, $nbSides, 1, 1, 1) Then
If _Sleep(500) Then Return
  EndIf
If LauchTroop($eGoblin, $nbSides, 1, 2) Then
If _Sleep(500) Then Return
  EndIf
If LauchTroop($eArcher, $nbSides, 2, 2) Then
If _Sleep(1) Then Return
  EndIf
If LauchTroop($eGoblin, $nbSides, 2, 2) Then
If _Sleep(500) Then Return
  EndIf

Upper = Func algorithm_AllTroops
Lower = algorithmTH() = Where you can edit the speed

By the way dinobot any idea how can i speed up the 2nd ware barbarian? there is a little delay in deploying the troops?

update: i got it already
Code:
if LauchTroop($eArcher, $nbSides, 1, 2) Then
If _Sleep(1) Then Return
   EndIf
If _Sleep(1) Then Return
Take delight in the LORD, and he will give you the desires of your heart - Psalm 37:4
Reply
 


Messages In This Thread
Faster deployment speed - by jondra - 02-05-2015, 05:16 AM
RE: Faster deployment speed - by DrImmo - 02-05-2015, 05:42 AM
RE: Faster deployment speed - by jondra - 02-05-2015, 06:02 AM
RE: Faster deployment speed - by mobbingalong - 02-05-2015, 11:40 AM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 11:54 AM
RE: Faster deployment speed - by Snarg - 02-05-2015, 12:04 PM
RE: Faster deployment speed - by load66 - 02-05-2015, 01:53 PM
RE: Faster deployment speed - by jb242 - 02-05-2015, 03:08 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 06:07 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 06:55 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 07:05 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 07:15 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 07:21 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 07:25 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 08:16 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 08:29 PM
RE: Faster deployment speed - by nonAS - 02-05-2015, 08:18 PM
RE: Faster deployment speed - by indy - 02-05-2015, 09:00 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 09:11 PM
RE: Faster deployment speed - by dinobot - 02-05-2015, 10:20 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 10:26 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 09:07 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 09:17 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 09:52 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 09:59 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 10:03 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 10:13 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 11:27 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 11:33 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 11:28 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 11:39 PM
RE: Faster deployment speed - by SongHyeKyo - 02-05-2015, 11:44 PM
RE: Faster deployment speed - by M Khalid - 02-05-2015, 11:42 PM
RE: Faster deployment speed - by jondra - 02-05-2015, 11:46 PM
RE: Faster deployment speed - by safar46 - 02-06-2015, 12:30 AM
RE: Faster deployment speed - by nonAS - 02-06-2015, 01:03 AM
RE: Faster deployment speed - by M Khalid - 02-06-2015, 02:04 AM
RE: Faster deployment speed - by M Khalid - 02-06-2015, 04:48 AM
RE: Faster deployment speed - by DrImmo - 02-06-2015, 04:55 AM
RE: Faster deployment speed - by jondra - 02-06-2015, 09:15 PM
RE: Faster deployment speed - by M Khalid - 02-06-2015, 09:24 PM
RE: Faster deployment speed - by SongHyeKyo - 02-06-2015, 11:09 PM
RE: Faster deployment speed - by jondra - 02-06-2015, 09:31 PM
RE: Faster deployment speed - by M Khalid - 02-06-2015, 09:49 PM
RE: Faster deployment speed - by dinobot - 02-06-2015, 09:49 PM
RE: Faster deployment speed - by jondra - 02-06-2015, 10:00 PM
RE: Faster deployment speed - by M Khalid - 02-06-2015, 11:27 PM
RE: Faster deployment speed - by knowjack20 - 02-07-2015, 01:19 PM
RE: Faster deployment speed - by M Khalid - 02-08-2015, 01:10 AM
RE: Faster deployment speed - by Sexagrim - 02-09-2015, 10:12 PM
RE: Faster deployment speed - by zealous - 02-18-2015, 12:04 AM
RE: Faster deployment speed - by Mattrix - 02-18-2015, 01:20 AM

Forum Jump:


Users browsing this thread: 18 Guest(s)

About The Bytecode Club

We're a community forum focused on Reverse Engineering, we try to target Java/Android but we also include other langauges/platforms. We pride ourselves in supporting and free and open sourced applications.

Website