// veg planter 		Ver 1.0
// Created by rwindmtg
// This macro plants up to 12 vegtables in a 4x3 grid.
// Note: IT WILL NOT WATER THE VEG FOR YOU JUST PLANT THEM.
// You need Global hotkeys enabled (under editor>>Prefences) and
// defined
//
// Usage:
// pin plant window where you want and place mouse over the veg that
// you want to plant then press the 'start' hotkey
// remember to adjust seeds and dist for your specific veg in inv
// recomend values for dist:
// onions = 4, cabbage = 6.
//
Constants
  //User define variables
  seeds = 9 // Number of veg to plant
  dist = 4 // distance between veg (clicks on small movment) defult 4
  
  // NON user defined variables
  // button positions
  vegX = 0
  vegY = 0
  ulx = 45
  uly = 85
  lx = 36
  ly = 100
  dlx = 45
  dly = 115
  ux = 60
  uy = 78
  urx = 76
  ury = 85
  rx = 81
  ry = 100
  drx = 76
  dry = 115
  dx = 60
  dy = 125
  plantX = 26
  plantY = 162
  locX = 0
  locY = 0
end
//selects the veg
delay 20
setconst vegX = {mousex}
setconst vegY = {mousey}
delay 20
call main

procedure main
  loop $seeds
    mousepos $vegX, $vegY
    delay 20
    rightclick
    delay 50
    if {loopno} = 1
      setconst locX = $ulx
      setconst locY = $uly
    end
    if {loopno} = 2
      setconst locX = $lx
      setconst locY = $ly
    end
    if {loopno} = 3
      setconst locX = $dlx
      setconst locY = $dly
    end
    if {loopno} = 4
      setconst locX = $ux
      setconst locY = $uy
    end
    if {loopno} = 5
       setconst locX = 12
       setconst locY = 71
    end
    if {loopno} = 6
      setconst locX = $dx
      setconst locY = $dy
    end
    if {loopno} = 7
      setconst locX = $urx
      setconst locY = $ury
    end
    if {loopno} = 8
      setconst locX = $rx
      setconst locY = $ry
    end
    if {loopno} = 9
      setconst locX = $drx
      setconst locY = $dry
    end
    if {loopno} = 10
      call rightshift
      setconst locX = $urx
      setconst locY = $ury
    end
    if {loopno} = 11
      call rightshift
      setconst locX = $rx
      setconst locY = $ry
    end
    if {loopno} = 12
      call rightshift
      setconst locX = $drx
      setconst locY = $dry
    end
    call plant
    delay 200
  end
end

procedure rightshift
  loop $dist
    mousepos $rx, $ry
    delay 20
    rightclick
  end
  delay 20
end

procedure plant
  loop $dist
    MousePos $locX, $locY
    delay 20
    rightclick
  end
  delay 20
  mousepos $plantX, $plantY
  delay 20
  rightclick
  delay 50
end
Bell asterisk
//made with AC Tool 5.4.0