xmd79

Gann Square of 144

Jan 1st, 2023
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 53.65 KB | None | 0 0
  1. // This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
  2. // © ThiagoSchmitz
  3.  
  4. //@version=5
  5. indicator("Gann Square of 144", overlay=true, max_lines_count=500, max_labels_count=500)
  6. // *****************************************************************************
  7. // ********************************* Constants *********************************
  8. // *****************************************************************************
  9. string groupInlineXYLabels = "X-Axis and Y-Axis Labels"
  10. string groupInlineExtraLines = "Extra Lines"
  11. string groupInlineColors = "colors"
  12. string groupInlineSquare = "squarecolors"
  13. int squares = 144
  14. int barIndex = bar_index
  15. float barHigh = high
  16. float barLow = low
  17. string lineDashed = line.style_dashed
  18. string lineDotted = line.style_dotted
  19. string lineSolid = line.style_solid
  20. string lineNone = label.style_none
  21. bool barstateIsNew = barstate.isnew
  22. bool barstateIsLast = barstate.islast
  23. color colorRed = color.red
  24. color colorWhite = color.white
  25.  
  26. // *****************************************************************************
  27. // ********************************* Inputs ************************************
  28. // *****************************************************************************
  29. int startDate = input.time(timestamp("2022-11-01"), "Starting Date")
  30. float maxPrice = input.float(69198.0, "Manual Max Price")
  31. float minPrice = input.float(17595.0, "Manual Min Price")
  32. bool autoPricesAndBar = input.bool(true, "Set Upper/Lower Prices and Start Bar Automatically")
  33. bool updateNewBar = input.bool(true, "Update at new bar")
  34. int candlesPerDivision = input.int(1, "Candles per division", minval=1)
  35. bool showTopXAxis = input.bool(false, "Top X-Axis", inline=groupInlineXYLabels, group=groupInlineXYLabels)
  36. bool showBottomXAxis = input.bool(true, "Bottom X-Axis", inline=groupInlineXYLabels, group=groupInlineXYLabels)
  37. bool showLeftYAxis = input.bool(false, "Left Y-Axis", inline=groupInlineXYLabels, group=groupInlineXYLabels)
  38. bool showRightYAxis = input.bool(true, "Right Y-Axis", inline=groupInlineXYLabels, group=groupInlineXYLabels)
  39. bool showPrices = input.bool(true, "Show Prices on the Right Y-Axis", inline=groupInlineXYLabels, group=groupInlineXYLabels)
  40. bool showDivisions = input.bool(true, "Show Vertical Divisions", inline=groupInlineExtraLines, group=groupInlineExtraLines)
  41. bool showExtraLines = input.bool(true, "Show Extra Lines", inline=groupInlineExtraLines, group=groupInlineExtraLines)
  42. bool showGrid = input.bool(true, "Show Grid", inline=groupInlineExtraLines, group=groupInlineExtraLines)
  43. bool showBackground = input.bool(true, "Show Background", inline=groupInlineExtraLines, group=groupInlineExtraLines)
  44. string patterns = input.string("None", "Line Patterns", options=["None", "Arrow", "Star", "36, 72, and 108", "Arrow Cross", "Corners and Cross", "Master"], group="patterns")
  45. color labelColor = input.color(color.green, "Numbers Color", inline=groupInlineColors, group=groupInlineColors)
  46. color divisionsColor = input.color(color.blue, "Vertical Lines Color", inline=groupInlineColors, group=groupInlineColors)
  47. color gridColor = input.color(color.gray, "Grid Color", inline=groupInlineColors, group=groupInlineColors)
  48. color TLSColor = input.color(color.new(color.green, 80), "Top Left Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  49. color TMSColor = input.color(color.new(color.red, 80), "Top Middle Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  50. color TRSColor = input.color(color.new(color.green, 80), "Top Right Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  51. color CLSColor = input.color(color.new(color.green, 80), "Center Left Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  52. color CMSColor = input.color(color.new(color.red, 80), "Center Middle Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  53. color CRSColor = input.color(color.new(color.green, 80), "Center Right Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  54. color BLSColor = input.color(color.new(color.green, 80), "Bottom Left Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  55. color BMSColor = input.color(color.new(color.red, 80), "Bottom Middle Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  56. color BRSColor = input.color(color.new(color.green, 80), "Bottom Right Square Color", inline=groupInlineSquare, group=groupInlineSquare)
  57.  
  58. // *****************************************************************************
  59. // ******************************** Variables **********************************
  60. // *****************************************************************************
  61. int startBarIndex = autoPricesAndBar ? barIndex - math.floor(squares * candlesPerDivision / 2) : barIndex
  62. int endBarIndex = startBarIndex + squares * candlesPerDivision
  63. int middleBarIndex = startBarIndex + squares * candlesPerDivision / 2
  64. int onethirdPriceBar = (endBarIndex - startBarIndex) / 3
  65. int barDiff = squares - math.abs(endBarIndex - barIndex)
  66. int barIndexDiff = barDiff <= 0 ? 1 : barDiff
  67. float atr = ta.atr(5)
  68. float highest = ta.highest(math.floor(squares * candlesPerDivision / 2) + 1)
  69. float lowest = ta.lowest(math.floor(squares * candlesPerDivision/ 2) + 1)
  70. float lowerPrice = autoPricesAndBar ? lowest : minPrice
  71. float upperPrice = autoPricesAndBar ? highest : maxPrice
  72. float middlePrice = lowerPrice + (upperPrice - lowerPrice) / 2
  73. float onethirdPrice = (upperPrice - lowerPrice) / 3
  74.  
  75. // *****************************************************************************
  76. // *************************** One-Time Variables ******************************
  77. // *****************************************************************************
  78. var box squareLines = box.new(barIndex, barHigh, barIndex, barLow, color.new(colorWhite, 50), 2, bgcolor=na)
  79. var int dateBarIndex = 0
  80. var bool buildSquareDone = false
  81. var bool buildInputsDone = false
  82. var bool[] dashedLineStyles = array.new_bool()
  83. var bool[] extendLines = array.new_bool()
  84. var bool[] showGroup = array.new_bool()
  85. var color[] lineColors = array.new_color()
  86. var label[] bottomXAxisArray = array.new_label()
  87. var label[] leftYAxisArray = array.new_label()
  88. var label[] rightYAxisArray = array.new_label()
  89. var label[] topXAxisArray = array.new_label()
  90. var line[] BLRArray = array.new_line()
  91. var line[] BLTArray = array.new_line()
  92. var line[] BRLArray = array.new_line()
  93. var line[] BRTArray = array.new_line()
  94. var line[] TLBArray = array.new_line()
  95. var line[] TLRArray = array.new_line()
  96. var line[] TRBArray = array.new_line()
  97. var line[] TRLArray = array.new_line()
  98. var line[] divisionsArray = array.new_line()
  99. var line[] extraArray = array.new_line()
  100. var line[] gridArray = array.new_line()
  101. var box back1Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=TLSColor)
  102. var box back2Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=TMSColor)
  103. var box back3Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=TRSColor)
  104. var box back4Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=CLSColor)
  105. var box back5Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=CMSColor)
  106. var box back6Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=CRSColor)
  107. var box back7Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=BLSColor)
  108. var box back8Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=BMSColor)
  109. var box back9Square = box.new(barIndex, barHigh, barIndex, barLow, na, 0, bgcolor=BRSColor)
  110.  
  111. // *****************************************************************************
  112. // ******************************** Fucntions **********************************
  113. // *****************************************************************************
  114.  
  115. // =============================================================================
  116. // * This function will update the box that goes on the edge of the Gann's
  117. // * square
  118. // =============================================================================
  119. updateBox() =>
  120. box.set_left(squareLines, startBarIndex)
  121. box.set_top(squareLines, upperPrice)
  122. box.set_right(squareLines, endBarIndex)
  123. box.set_bottom(squareLines, lowerPrice)
  124.  
  125. // =============================================================================
  126. // * This function will update the background of the Gann's square
  127. // =============================================================================
  128. updateBackgrounds() =>
  129. s1 = startBarIndex
  130. s2 = startBarIndex + ((squares / 3) * candlesPerDivision)
  131. s3 = startBarIndex + ((squares / 3) * 2 * candlesPerDivision)
  132. s4 = endBarIndex
  133. t1 = upperPrice
  134. t2 = upperPrice - ((upperPrice - lowerPrice) / 3)
  135. t3 = upperPrice - ((upperPrice - lowerPrice) / 3) * 2
  136. t4 = lowerPrice
  137.  
  138. box.set_left(back1Square, s1)
  139. box.set_right(back1Square, s2)
  140. box.set_top(back1Square, t1)
  141. box.set_bottom(back1Square, t2)
  142.  
  143. box.set_left(back2Square, s2)
  144. box.set_right(back2Square, s3)
  145. box.set_top(back2Square, t1)
  146. box.set_bottom(back2Square, t2)
  147.  
  148. box.set_left(back3Square, s3)
  149. box.set_right(back3Square, s4)
  150. box.set_top(back3Square, t1)
  151. box.set_bottom(back3Square, t2)
  152.  
  153. box.set_left(back4Square, s1)
  154. box.set_right(back4Square, s2)
  155. box.set_top(back4Square, t2)
  156. box.set_bottom(back4Square, t3)
  157.  
  158. box.set_left(back5Square, s2)
  159. box.set_right(back5Square, s3)
  160. box.set_top(back5Square, t2)
  161. box.set_bottom(back5Square, t3)
  162.  
  163. box.set_left(back6Square, s3)
  164. box.set_right(back6Square, s4)
  165. box.set_top(back6Square, t2)
  166. box.set_bottom(back6Square, t3)
  167.  
  168. box.set_left(back7Square, s1)
  169. box.set_right(back7Square, s2)
  170. box.set_top(back7Square, t3)
  171. box.set_bottom(back7Square, t4)
  172.  
  173. box.set_left(back8Square, s2)
  174. box.set_right(back8Square, s3)
  175. box.set_top(back8Square, t3)
  176. box.set_bottom(back8Square, t4)
  177.  
  178. box.set_left(back9Square, s3)
  179. box.set_right(back9Square, s4)
  180. box.set_top(back9Square, t3)
  181. box.set_bottom(back9Square, t4)
  182.  
  183. // =============================================================================
  184. // * Build both X-Axis and y-Axis labels
  185. // * It will use the topXAxisArray, bottomXAxisArray, rightYAxisArray, and
  186. // * leftYAxisArray arrays to store each label, if they are enabled to be shown
  187. // =============================================================================
  188. buildAxis() =>
  189. for int j = 0 to squares by 6
  190. if showTopXAxis
  191. array.push(topXAxisArray, label.new(startBarIndex + j * candlesPerDivision, upperPrice + atr / 4, str.tostring(j), style=lineNone, textcolor=labelColor))
  192. if showBottomXAxis
  193. array.push(bottomXAxisArray, label.new(startBarIndex + j * candlesPerDivision, lowerPrice - atr / 2, str.tostring(j), style=lineNone, textcolor=labelColor))
  194. if showRightYAxis
  195. price = upperPrice - (upperPrice - lowerPrice) / squares * j
  196. t = str.tostring(j) + (showPrices ? " (" + str.tostring(math.round_to_mintick(price)) + ")" : "")
  197. array.push(rightYAxisArray, label.new(endBarIndex + 8 * candlesPerDivision, price, t, style=lineNone, textcolor=labelColor))
  198. if showLeftYAxis
  199. array.push(leftYAxisArray, label.new(startBarIndex - 3, upperPrice - (upperPrice - lowerPrice) / squares * j, str.tostring(j), style=lineNone, textcolor=labelColor))
  200.  
  201. // =============================================================================
  202. // * Update both X-Axis and y-Axis labels
  203. // =============================================================================
  204. updateAxis() =>
  205. for int j = 0 to squares - 1 by 6
  206. if showTopXAxis
  207. label.set_x(array.get(topXAxisArray, j / 6), startBarIndex + j * candlesPerDivision)
  208. label.set_y(array.get(topXAxisArray, j / 6), upperPrice + atr / 4)
  209. if showBottomXAxis
  210. label.set_x(array.get(bottomXAxisArray, j / 6), startBarIndex + j * candlesPerDivision)
  211. label.set_y(array.get(bottomXAxisArray, j / 6), lowerPrice - atr / 2)
  212. if showRightYAxis
  213. label.set_x(array.get(rightYAxisArray, j / 6), endBarIndex + 8 * candlesPerDivision)
  214. label.set_y(array.get(rightYAxisArray, j / 6), upperPrice - (upperPrice - lowerPrice) / squares * j)
  215. if showLeftYAxis
  216. label.set_x(array.get(rightYAxisArray, j / 6), startBarIndex - 3)
  217. label.set_y(array.get(rightYAxisArray, j / 6), upperPrice - (upperPrice - lowerPrice) / squares * j)
  218.  
  219. // =============================================================================
  220. // * Build the vertical divisions to divide the square in 9 smaller squares
  221. // =============================================================================
  222. buildDivisions() =>
  223. array.push(divisionsArray, line.new(startBarIndex, lowerPrice + onethirdPrice, endBarIndex, lowerPrice + onethirdPrice, color=divisionsColor, style=lineDashed))
  224. array.push(divisionsArray, line.new(startBarIndex, lowerPrice + onethirdPrice * 2, endBarIndex, lowerPrice + onethirdPrice * 2, color=divisionsColor, style=lineDashed))
  225. array.push(divisionsArray, line.new(startBarIndex + onethirdPriceBar, upperPrice, startBarIndex + onethirdPriceBar, lowerPrice, color=divisionsColor, style=lineDashed))
  226. array.push(divisionsArray, line.new(startBarIndex + onethirdPriceBar * 2, upperPrice, startBarIndex + onethirdPriceBar * 2, lowerPrice, color=divisionsColor, style=lineDashed))
  227.  
  228. // =============================================================================
  229. // * Update the vertical divisions
  230. // =============================================================================
  231. updateDivisions() =>
  232. line.set_xy1(array.get(divisionsArray, 0), startBarIndex, lowerPrice + onethirdPrice)
  233. line.set_xy2(array.get(divisionsArray, 0), endBarIndex, lowerPrice + onethirdPrice)
  234. line.set_xy1(array.get(divisionsArray, 1), startBarIndex, lowerPrice + onethirdPrice * 2)
  235. line.set_xy2(array.get(divisionsArray, 1), endBarIndex, lowerPrice + onethirdPrice * 2)
  236. line.set_xy1(array.get(divisionsArray, 2), startBarIndex + onethirdPriceBar, upperPrice)
  237. line.set_xy2(array.get(divisionsArray, 2), startBarIndex + onethirdPriceBar, lowerPrice)
  238. line.set_xy1(array.get(divisionsArray, 3), startBarIndex + onethirdPriceBar * 2, upperPrice)
  239. line.set_xy2(array.get(divisionsArray, 3), startBarIndex + onethirdPriceBar * 2, lowerPrice)
  240.  
  241. // =============================================================================
  242. // * Build the Gann's square. It will create lines based on the inputs and store
  243. // * them in some arrays. It will use the showGroup array to check if the line
  244. // * needs to be created or not. If showExtraLines is enabled, it will create
  245. // * specific lines to provide the original Gann's Square format
  246. // =============================================================================
  247. buildSquare() =>
  248. for int i = 0 to (squares / 6) - 1
  249. int endIndex = startBarIndex + 6 * (i + 1) * candlesPerDivision
  250. float endPrice = upperPrice - ((upperPrice - lowerPrice) / squares) * 6 * (i + 1)
  251. string style = array.get(dashedLineStyles, i) ? lineDashed : lineSolid
  252. string extend = array.get(extendLines, i) ? extend.both : extend.none
  253. if array.get(showGroup, i * 8)
  254. // Top Left Bottom
  255. array.push(TLBArray, line.new(startBarIndex, upperPrice, endIndex, lowerPrice, color=array.get(lineColors, i), style=style, extend=extend))
  256. if array.get(showGroup, i * 8 + 1)
  257. // Top Left Right
  258. array.push(TLRArray, line.new(startBarIndex, upperPrice, endBarIndex, endPrice, color=array.get(lineColors, i), style=style, extend=extend))
  259. if array.get(showGroup, i * 8 + 2)
  260. // Bottom Left Top
  261. array.push(BLTArray, line.new(startBarIndex, lowerPrice, endIndex, upperPrice, color=array.get(lineColors, i), style=style, extend=extend))
  262. if array.get(showGroup, i * 8 + 3)
  263. // Bottom Left Right
  264. array.push(BLRArray, line.new(startBarIndex, lowerPrice, endBarIndex, endPrice, color=array.get(lineColors, i), style=style, extend=extend))
  265. if array.get(showGroup, i * 8 + 4)
  266. // Top Right Bottom
  267. array.push(TRBArray, line.new(endBarIndex, upperPrice, endIndex, lowerPrice, color=array.get(lineColors, i), style=style, extend=extend))
  268. if array.get(showGroup, i * 8 + 5)
  269. // Top Right Left
  270. array.push(TRLArray, line.new(endBarIndex, upperPrice, startBarIndex, endPrice, color=array.get(lineColors, i), style=style, extend=extend))
  271. if array.get(showGroup, i * 8 + 6)
  272. // Bottom Right Top
  273. array.push(BRTArray, line.new(endBarIndex, lowerPrice, endIndex, upperPrice, color=array.get(lineColors, i), style=style, extend=extend))
  274. if array.get(showGroup, i * 8 + 7)
  275. // Bottom Right Left
  276. array.push(BRLArray, line.new(endBarIndex, lowerPrice, startBarIndex, endPrice, color=array.get(lineColors, i), style=style, extend=extend))
  277. if showExtraLines
  278. array.push(extraArray, line.new(middleBarIndex, upperPrice, startBarIndex, upperPrice - ((upperPrice - lowerPrice) / squares) * 36, color=colorRed, style=lineDashed))
  279. array.push(extraArray, line.new(middleBarIndex, upperPrice, endBarIndex, upperPrice - ((upperPrice - lowerPrice) / squares) * 36, color=colorRed, style=lineDashed))
  280. array.push(extraArray, line.new(middleBarIndex, lowerPrice, startBarIndex, upperPrice - ((upperPrice - lowerPrice) / squares) * 108, color=colorRed, style=lineDashed))
  281. array.push(extraArray, line.new(middleBarIndex, lowerPrice, endBarIndex, upperPrice - ((upperPrice - lowerPrice) / squares) * 108, color=colorRed, style=lineDashed))
  282.  
  283. // =============================================================================
  284. // * Update each line created for the Gann's square
  285. // =============================================================================
  286. updateSquare() =>
  287. if array.size(TLBArray) == (squares / 6) - 1 and
  288. array.size(TLRArray) == (squares / 6) - 1 and
  289. array.size(BLTArray) == (squares / 6) - 1
  290.  
  291. for int i = 0 to (squares / 6) - 1
  292. int endIndex = startBarIndex + 6 * i * candlesPerDivision
  293. float endPrice = upperPrice - ((upperPrice - lowerPrice) / squares) * 6 * i
  294. if array.get(showGroup, i * 8)
  295. // Top Left Bottom
  296. line.set_xy1(array.get(TLBArray, i), startBarIndex, upperPrice)
  297. line.set_xy2(array.get(TLBArray, i), endIndex, lowerPrice)
  298. if array.get(showGroup, i * 8 + 1)
  299. // Top Left Right
  300. line.set_xy1(array.get(TLRArray, i), startBarIndex, upperPrice)
  301. line.set_xy2(array.get(TLRArray, i), endBarIndex, endPrice)
  302. if array.get(showGroup, i * 8 + 2)
  303. // Bottom Left Top
  304. line.set_xy1(array.get(BLTArray, i), startBarIndex, lowerPrice)
  305. line.set_xy2(array.get(BLTArray, i), endIndex, upperPrice)
  306. if array.get(showGroup, i * 8 + 3)
  307. // Bottom Left Right
  308. line.set_xy1(array.get(BLRArray, i), startBarIndex, lowerPrice)
  309. line.set_xy2(array.get(BLRArray, i), endBarIndex, endPrice)
  310. if array.get(showGroup, i * 8 + 4)
  311. // Top Right Bottom
  312. line.set_xy1(array.get(TRBArray, i), endBarIndex, upperPrice)
  313. line.set_xy2(array.get(TRBArray, i), endIndex, lowerPrice)
  314. if array.get(showGroup, i * 8 + 5)
  315. // Top Right Left
  316. line.set_xy1(array.get(TRLArray, i), endBarIndex, upperPrice)
  317. line.set_xy2(array.get(TRLArray, i), startBarIndex, endPrice)
  318. if array.get(showGroup, i * 8 + 6)
  319. // Bottom Right Top
  320. line.set_xy1(array.get(BRTArray, i), endBarIndex, lowerPrice)
  321. line.set_xy2(array.get(BRTArray, i), endIndex, upperPrice)
  322. if array.get(showGroup, i * 8 + 7)
  323. // Bottom Right Left
  324. line.set_xy1(array.get(BRLArray, i), endBarIndex, lowerPrice)
  325. line.set_xy2(array.get(BRLArray, i), startBarIndex, endPrice)
  326.  
  327. // =============================================================================
  328. // * Create the grid lines for reference
  329. // =============================================================================
  330. buildGrid() =>
  331. for int i = 0 to 23
  332. index = startBarIndex + 6 * (i + 1) * candlesPerDivision
  333. price = upperPrice - ((upperPrice - lowerPrice) / squares) * 6 * (i + 1)
  334. array.push(gridArray, line.new(index, upperPrice, index, lowerPrice, color=gridColor, style=lineDotted))
  335. array.push(gridArray, line.new(startBarIndex, price, endBarIndex, price, color=gridColor, style=lineDotted))
  336.  
  337. // =============================================================================
  338. // * Update the grid lines
  339. // =============================================================================
  340. updateGrid() =>
  341. for int i = 0 to 23
  342. index = startBarIndex + 6 * (i + 1) * candlesPerDivision
  343. price = upperPrice - ((upperPrice - lowerPrice) / squares) * 6 * (i + 1)
  344. line.set_xy1(array.get(gridArray, i * 2), index, upperPrice)
  345. line.set_xy2(array.get(gridArray, i * 2), index, lowerPrice)
  346. line.set_xy1(array.get(gridArray, i * 2 + 1), startBarIndex, price)
  347. line.set_xy2(array.get(gridArray, i * 2 + 1), endBarIndex, price)
  348.  
  349. // =============================================================================
  350. // * Set lines pattern to override the parameters input of each division. When an
  351. // * option besides None is selected, it will ignore the selections of each line
  352. // =============================================================================
  353. setPattern() =>
  354. if patterns != "None"
  355. for int i = 0 to array.size(showGroup) - 1
  356. array.set(showGroup, i, false)
  357. if patterns == "Arrow"
  358. array.set(showGroup, 88, true) // Top Left to Bottom 72
  359. array.set(showGroup, 89, true) // Top Left to Right 72
  360. array.set(showGroup, 90, true) // Bottom Left to Top 72
  361. array.set(showGroup, 91, true) // Bottom Left to Right 72
  362. else if patterns == "Star"
  363. array.set(showGroup, 88, true) // Top Left to Bottom 72
  364. array.set(showGroup, 89, true) // Top Left to Right 72
  365. array.set(showGroup, 90, true) // Bottom Left to Top 72
  366. array.set(showGroup, 91, true) // Bottom Left to Right 72
  367. array.set(showGroup, 92, true) // Top Right to Bottom 72
  368. array.set(showGroup, 93, true) // Top Right to Left 72
  369. array.set(showGroup, 94, true) // Bottom Right to Top 72
  370. array.set(showGroup, 95, true) // Bottom Right to Left 72
  371. else if patterns == "36, 72, and 108"
  372. array.set(showGroup, 40, true) // Top Left to Bottom 36
  373. array.set(showGroup, 41, true) // Top Left to Right 36
  374. array.set(showGroup, 42, true) // Bottom Left to Top 36
  375. array.set(showGroup, 45, true) // Top Right to Left 36
  376. array.set(showGroup, 88, true) // Top Left to Bottom 72
  377. array.set(showGroup, 89, true) // Top Left to Right 72
  378. array.set(showGroup, 90, true) // Bottom Left to Top 72
  379. array.set(showGroup, 91, true) // Bottom Left to Right 72
  380. array.set(showGroup, 92, true) // Top Right to Bottom 72
  381. array.set(showGroup, 93, true) // Top Right to Left 72
  382. array.set(showGroup, 94, true) // Bottom Right to Top 72
  383. array.set(showGroup, 95, true) // Bottom Right to Left 72
  384. array.set(showGroup, 139, true) // Bottom Left to Right 108
  385. array.set(showGroup, 140, true) // Top Right to Bottom 108
  386. array.set(showGroup, 142, true) // Bottom Right to Top 108
  387. array.set(showGroup, 143, true) // Bottom Right to Left 108
  388. array.set(showGroup, 184, true) // Top Left to Corner 144
  389. array.set(showGroup, 186, true) // Top Right to Corner 144
  390. else if patterns == "Arrow Cross"
  391. array.set(showGroup, 88, true) // Top Left to Bottom 72
  392. array.set(showGroup, 89, true) // Top Left to Right 72
  393. array.set(showGroup, 90, true) // Bottom Left to Top 72
  394. array.set(showGroup, 91, true) // Bottom Left to Right 72
  395. array.set(showGroup, 184, true) // Top Left to Corner 144
  396. array.set(showGroup, 186, true) // Top Right to Corner 144
  397. else if patterns == "Corners and Cross"
  398. array.set(showGroup, 88, true) // Top Left to Bottom 72
  399. array.set(showGroup, 89, true) // Top Left to Right 72
  400. array.set(showGroup, 90, true) // Bottom Left to Top 72
  401. array.set(showGroup, 91, true) // Bottom Left to Right 72
  402. array.set(showGroup, 92, true) // Top Right to Bottom 72
  403. array.set(showGroup, 93, true) // Top Right to Left 72
  404. array.set(showGroup, 94, true) // Bottom Right to Top 72
  405. array.set(showGroup, 95, true) // Bottom Right to Left 72
  406. array.set(showGroup, 184, true) // Top Left to Corner 144
  407. array.set(showGroup, 186, true) // Top Right to Corner 144
  408. else if patterns == "Master"
  409. array.set(showGroup, 42, true) // Bottom Left to Top 36
  410. array.set(showGroup, 43, true) // Bottom Left to Right 36
  411. array.set(showGroup, 88, true) // Top Left to Bottom 72
  412. array.set(showGroup, 89, true) // Top Left to Right 72
  413. array.set(showGroup, 90, true) // Bottom Left to Top 72
  414. array.set(showGroup, 91, true) // Bottom Left to Right 72
  415. array.set(showGroup, 138, true) // Bottom Left to Top 108
  416. array.set(showGroup, 139, true) // Bottom Left to Right 108
  417. array.set(showGroup, 184, true) // Top Left to Corner 144
  418. array.set(showGroup, 186, true) // Top Right to Corner 144
  419.  
  420. // *****************************************************************************
  421. // ************************** Run On Every Tick ********************************
  422. // *****************************************************************************
  423. if updateNewBar and buildSquareDone and barstateIsNew and autoPricesAndBar
  424. updateSquare()
  425. updateAxis()
  426. updateBox()
  427. if showDivisions
  428. updateDivisions()
  429. if showGrid
  430. updateGrid()
  431. // if showBackground
  432. // updateBackgrounds()
  433.  
  434. // *****************************************************************************
  435. // ****************************** Run Once *************************************
  436. // *****************************************************************************
  437. if buildInputsDone
  438. if time == startDate
  439. dateBarIndex := barIndex
  440. if barstateIsLast and not buildSquareDone
  441. setPattern()
  442. updateBox()
  443. buildSquare()
  444. buildAxis()
  445. if showDivisions
  446. buildDivisions()
  447. if showGrid
  448. buildGrid()
  449. if showBackground
  450. updateBackgrounds()
  451. buildSquareDone := true
  452.  
  453. // =============================================================================
  454. // * Create all the lines inputs, together with the color of each one, line style and
  455. // * extend type. The default values are those originally found in W.D. Gann's book.
  456. // * The order of each line matters for the comparison inside the functions
  457. // =============================================================================
  458. if not buildInputsDone
  459. buildInputsDone := true
  460. lineColors := array.concat(lineColors, array.from(
  461. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 6"),
  462. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 12"),
  463. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 18"),
  464. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 24"),
  465. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 30"),
  466. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 36"),
  467. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 42"),
  468. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 48"),
  469. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 54"),
  470. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 60"),
  471. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 66"),
  472. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 72"),
  473. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 78"),
  474. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 84"),
  475. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 90"),
  476. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 96"),
  477. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 102"),
  478. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 108"),
  479. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 114"),
  480. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 120"),
  481. input.color(color.red, "Line Color", inline="line", group="Connections from corners to 126"),
  482. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 132"),
  483. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 138"),
  484. input.color(color.green, "Line Color", inline="line", group="Connections from corners to 144")))
  485.  
  486. extendLines := array.concat(extendLines, array.from(
  487. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 6"),
  488. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 12"),
  489. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 18"),
  490. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 24"),
  491. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 30"),
  492. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 36"),
  493. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 42"),
  494. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 48"),
  495. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 54"),
  496. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 60"),
  497. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 66"),
  498. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 72"),
  499. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 78"),
  500. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 84"),
  501. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 90"),
  502. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 96"),
  503. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 102"),
  504. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 108"),
  505. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 114"),
  506. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 120"),
  507. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 126"),
  508. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 132"),
  509. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 138"),
  510. input.bool(false, "Extend Line", inline="line", group="Connections from corners to 144")))
  511.  
  512. dashedLineStyles := array.concat(dashedLineStyles, array.from(
  513. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 6"),
  514. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 12"),
  515. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 18"),
  516. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 24"),
  517. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 30"),
  518. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 36"),
  519. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 42"),
  520. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 48"),
  521. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 54"),
  522. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 60"),
  523. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 66"),
  524. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 72"),
  525. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 78"),
  526. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 84"),
  527. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 90"),
  528. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 96"),
  529. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 102"),
  530. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 108"),
  531. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 114"),
  532. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 120"),
  533. input.bool(true, "Dashed Line", inline="line", group="Connections from corners to 126"),
  534. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 132"),
  535. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 138"),
  536. input.bool(false, "Dashed Line", inline="line", group="Connections from corners to 144")))
  537.  
  538. showGroup := array.concat(showGroup, array.from(
  539. input.bool(false, "┏ ↓", inline="6", group="Connections from corners to 6"),
  540. input.bool(false, "┏ →", inline="6", group="Connections from corners to 6"),
  541. input.bool(false, "┗ ↑", inline="6", group="Connections from corners to 6"),
  542. input.bool(false, "┗ →", inline="6", group="Connections from corners to 6"),
  543. input.bool(false, "┓ ←", inline="6", group="Connections from corners to 6"),
  544. input.bool(false, "┓ ↓", inline="6", group="Connections from corners to 6"),
  545. input.bool(false, "┛ ←", inline="6", group="Connections from corners to 6"),
  546. input.bool(false, "┛ ↑", inline="6", group="Connections from corners to 6"),
  547. input.bool(false, "┏ ↓", inline="12", group="Connections from corners to 12"),
  548. input.bool(false, "┏ →", inline="12", group="Connections from corners to 12"),
  549. input.bool(false, "┗ ↑", inline="12", group="Connections from corners to 12"),
  550. input.bool(false, "┗ →", inline="12", group="Connections from corners to 12"),
  551. input.bool(false, "┓ ←", inline="12", group="Connections from corners to 12"),
  552. input.bool(false, "┓ ↓", inline="12", group="Connections from corners to 12"),
  553. input.bool(false, "┛ ←", inline="12", group="Connections from corners to 12"),
  554. input.bool(false, "┛ ↑", inline="12", group="Connections from corners to 12"),
  555. input.bool(true, "┏ ↓", inline="18", group="Connections from corners to 18"),
  556. input.bool(true, "┏ →", inline="18", group="Connections from corners to 18"),
  557. input.bool(true, "┗ ↑", inline="18", group="Connections from corners to 18"),
  558. input.bool(false, "┗ →", inline="18", group="Connections from corners to 18"),
  559. input.bool(false, "┓ ←", inline="18", group="Connections from corners to 18"),
  560. input.bool(false, "┓ ↓", inline="18", group="Connections from corners to 18"),
  561. input.bool(false, "┛ ←", inline="18", group="Connections from corners to 18"),
  562. input.bool(false, "┛ ↑", inline="18", group="Connections from corners to 18"),
  563. input.bool(false, "┏ ↓", inline="24", group="Connections from corners to 24"),
  564. input.bool(false, "┏ →", inline="24", group="Connections from corners to 24"),
  565. input.bool(false, "┗ ↑", inline="24", group="Connections from corners to 24"),
  566. input.bool(false, "┗ →", inline="24", group="Connections from corners to 24"),
  567. input.bool(false, "┓ ←", inline="24", group="Connections from corners to 24"),
  568. input.bool(false, "┓ ↓", inline="24", group="Connections from corners to 24"),
  569. input.bool(false, "┛ ←", inline="24", group="Connections from corners to 24"),
  570. input.bool(false, "┛ ↑", inline="24", group="Connections from corners to 24"),
  571. input.bool(false, "┏ ↓", inline="30", group="Connections from corners to 30"),
  572. input.bool(false, "┏ →", inline="30", group="Connections from corners to 30"),
  573. input.bool(false, "┗ ↑", inline="30", group="Connections from corners to 30"),
  574. input.bool(false, "┗ →", inline="30", group="Connections from corners to 30"),
  575. input.bool(false, "┓ ←", inline="30", group="Connections from corners to 30"),
  576. input.bool(false, "┓ ↓", inline="30", group="Connections from corners to 30"),
  577. input.bool(false, "┛ ←", inline="30", group="Connections from corners to 30"),
  578. input.bool(false, "┛ ↑", inline="30", group="Connections from corners to 30"),
  579. input.bool(true, "┏ ↓", inline="36", group="Connections from corners to 36"),
  580. input.bool(true, "┏ →", inline="36", group="Connections from corners to 36"),
  581. input.bool(true, "┗ ↑", inline="36", group="Connections from corners to 36"),
  582. input.bool(false, "┗ →", inline="36", group="Connections from corners to 36"),
  583. input.bool(false, "┓ ←", inline="36", group="Connections from corners to 36"),
  584. input.bool(false, "┓ ↓", inline="36", group="Connections from corners to 36"),
  585. input.bool(false, "┛ ←", inline="36", group="Connections from corners to 36"),
  586. input.bool(false, "┛ ↑", inline="36", group="Connections from corners to 36"),
  587. input.bool(false, "┏ ↓", inline="42", group="Connections from corners to 42"),
  588. input.bool(false, "┏ →", inline="42", group="Connections from corners to 42"),
  589. input.bool(false, "┗ ↑", inline="42", group="Connections from corners to 42"),
  590. input.bool(false, "┗ →", inline="42", group="Connections from corners to 42"),
  591. input.bool(false, "┓ ←", inline="42", group="Connections from corners to 42"),
  592. input.bool(false, "┓ ↓", inline="42", group="Connections from corners to 42"),
  593. input.bool(false, "┛ ←", inline="42", group="Connections from corners to 42"),
  594. input.bool(false, "┛ ↑", inline="42", group="Connections from corners to 42"),
  595. input.bool(true, "┏ ↓", inline="48", group="Connections from corners to 48"),
  596. input.bool(true, "┏ →", inline="48", group="Connections from corners to 48"),
  597. input.bool(true, "┗ ↑", inline="48", group="Connections from corners to 48"),
  598. input.bool(false, "┗ →", inline="48", group="Connections from corners to 48"),
  599. input.bool(false, "┓ ←", inline="48", group="Connections from corners to 48"),
  600. input.bool(false, "┓ ↓", inline="48", group="Connections from corners to 48"),
  601. input.bool(false, "┛ ←", inline="48", group="Connections from corners to 48"),
  602. input.bool(false, "┛ ↑", inline="48", group="Connections from corners to 48"),
  603. input.bool(false, "┏ ↓", inline="54", group="Connections from corners to 54"),
  604. input.bool(false, "┏ →", inline="54", group="Connections from corners to 54"),
  605. input.bool(false, "┗ ↑", inline="54", group="Connections from corners to 54"),
  606. input.bool(false, "┗ →", inline="54", group="Connections from corners to 54"),
  607. input.bool(false, "┓ ←", inline="54", group="Connections from corners to 54"),
  608. input.bool(false, "┓ ↓", inline="54", group="Connections from corners to 54"),
  609. input.bool(false, "┛ ←", inline="54", group="Connections from corners to 54"),
  610. input.bool(false, "┛ ↑", inline="54", group="Connections from corners to 54"),
  611. input.bool(false, "┏ ↓", inline="60", group="Connections from corners to 60"),
  612. input.bool(false, "┏ →", inline="60", group="Connections from corners to 60"),
  613. input.bool(false, "┗ ↑", inline="60", group="Connections from corners to 60"),
  614. input.bool(false, "┗ →", inline="60", group="Connections from corners to 60"),
  615. input.bool(false, "┓ ←", inline="60", group="Connections from corners to 60"),
  616. input.bool(false, "┓ ↓", inline="60", group="Connections from corners to 60"),
  617. input.bool(false, "┛ ←", inline="60", group="Connections from corners to 60"),
  618. input.bool(false, "┛ ↑", inline="60", group="Connections from corners to 60"),
  619. input.bool(false, "┏ ↓", inline="66", group="Connections from corners to 66"),
  620. input.bool(false, "┏ →", inline="66", group="Connections from corners to 66"),
  621. input.bool(false, "┗ ↑", inline="66", group="Connections from corners to 66"),
  622. input.bool(false, "┗ →", inline="66", group="Connections from corners to 66"),
  623. input.bool(false, "┓ ←", inline="66", group="Connections from corners to 66"),
  624. input.bool(false, "┓ ↓", inline="66", group="Connections from corners to 66"),
  625. input.bool(false, "┛ ←", inline="66", group="Connections from corners to 66"),
  626. input.bool(false, "┛ ↑", inline="66", group="Connections from corners to 66"),
  627. input.bool(true, "┏ ↓", inline="72", group="Connections from corners to 72"),
  628. input.bool(true, "┏ →", inline="72", group="Connections from corners to 72"),
  629. input.bool(true, "┗ ↑", inline="72", group="Connections from corners to 72"),
  630. input.bool(true, "┗ →", inline="72", group="Connections from corners to 72"),
  631. input.bool(true, "┓ ←", inline="72", group="Connections from corners to 72"),
  632. input.bool(true, "┓ ↓", inline="72", group="Connections from corners to 72"),
  633. input.bool(true, "┛ ←", inline="72", group="Connections from corners to 72"),
  634. input.bool(true, "┛ ↑", inline="72", group="Connections from corners to 72"),
  635. input.bool(false, "┏ ↓", inline="78", group="Connections from corners to 78"),
  636. input.bool(false, "┏ →", inline="78", group="Connections from corners to 78"),
  637. input.bool(false, "┗ ↑", inline="78", group="Connections from corners to 78"),
  638. input.bool(false, "┗ →", inline="78", group="Connections from corners to 78"),
  639. input.bool(false, "┓ ←", inline="78", group="Connections from corners to 78"),
  640. input.bool(false, "┓ ↓", inline="78", group="Connections from corners to 78"),
  641. input.bool(false, "┛ ←", inline="78", group="Connections from corners to 78"),
  642. input.bool(false, "┛ ↑", inline="78", group="Connections from corners to 78"),
  643. input.bool(false, "┏ ↓", inline="84", group="Connections from corners to 84"),
  644. input.bool(false, "┏ →", inline="84", group="Connections from corners to 84"),
  645. input.bool(false, "┗ ↑", inline="84", group="Connections from corners to 84"),
  646. input.bool(false, "┗ →", inline="84", group="Connections from corners to 84"),
  647. input.bool(false, "┓ ←", inline="84", group="Connections from corners to 84"),
  648. input.bool(false, "┓ ↓", inline="84", group="Connections from corners to 84"),
  649. input.bool(false, "┛ ←", inline="84", group="Connections from corners to 84"),
  650. input.bool(false, "┛ ↑", inline="84", group="Connections from corners to 84"),
  651. input.bool(false, "┏ ↓", inline="90", group="Connections from corners to 90"),
  652. input.bool(false, "┏ →", inline="90", group="Connections from corners to 90"),
  653. input.bool(false, "┗ ↑", inline="90", group="Connections from corners to 90"),
  654. input.bool(false, "┗ →", inline="90", group="Connections from corners to 90"),
  655. input.bool(false, "┓ ←", inline="90", group="Connections from corners to 90"),
  656. input.bool(false, "┓ ↓", inline="90", group="Connections from corners to 90"),
  657. input.bool(false, "┛ ←", inline="90", group="Connections from corners to 90"),
  658. input.bool(false, "┛ ↑", inline="90", group="Connections from corners to 90"),
  659. input.bool(false, "┏ ↓", inline="96", group="Connections from corners to 96"),
  660. input.bool(false, "┏ →", inline="96", group="Connections from corners to 96"),
  661. input.bool(false, "┗ ↑", inline="96", group="Connections from corners to 96"),
  662. input.bool(true, "┗ →", inline="96", group="Connections from corners to 96"),
  663. input.bool(false, "┓ ←", inline="96", group="Connections from corners to 96"),
  664. input.bool(false, "┓ ↓", inline="96", group="Connections from corners to 96"),
  665. input.bool(false, "┛ ←", inline="96", group="Connections from corners to 96"),
  666. input.bool(false, "┛ ↑", inline="96", group="Connections from corners to 96"),
  667. input.bool(false, "┏ ↓", inline="102", group="Connections from corners to 102"),
  668. input.bool(false, "┏ →", inline="102", group="Connections from corners to 102"),
  669. input.bool(false, "┗ ↑", inline="102", group="Connections from corners to 102"),
  670. input.bool(false, "┗ →", inline="102", group="Connections from corners to 102"),
  671. input.bool(false, "┓ ←", inline="102", group="Connections from corners to 102"),
  672. input.bool(false, "┓ ↓", inline="102", group="Connections from corners to 102"),
  673. input.bool(false, "┛ ←", inline="102", group="Connections from corners to 102"),
  674. input.bool(false, "┛ ↑", inline="102", group="Connections from corners to 102"),
  675. input.bool(false, "┏ ↓", inline="108", group="Connections from corners to 108"),
  676. input.bool(false, "┏ →", inline="108", group="Connections from corners to 108"),
  677. input.bool(false, "┗ ↑", inline="108", group="Connections from corners to 108"),
  678. input.bool(true, "┗ →", inline="108", group="Connections from corners to 108"),
  679. input.bool(false, "┓ ←", inline="108", group="Connections from corners to 108"),
  680. input.bool(false, "┓ ↓", inline="108", group="Connections from corners to 108"),
  681. input.bool(false, "┛ ←", inline="108", group="Connections from corners to 108"),
  682. input.bool(false, "┛ ↑", inline="108", group="Connections from corners to 108"),
  683. input.bool(false, "┏ ↓", inline="114", group="Connections from corners to 114"),
  684. input.bool(false, "┏ →", inline="114", group="Connections from corners to 114"),
  685. input.bool(false, "┗ ↑", inline="114", group="Connections from corners to 114"),
  686. input.bool(false, "┗ →", inline="114", group="Connections from corners to 114"),
  687. input.bool(false, "┓ ←", inline="114", group="Connections from corners to 114"),
  688. input.bool(false, "┓ ↓", inline="114", group="Connections from corners to 114"),
  689. input.bool(false, "┛ ←", inline="114", group="Connections from corners to 114"),
  690. input.bool(false, "┛ ↑", inline="114", group="Connections from corners to 114"),
  691. input.bool(false, "┏ ↓", inline="120", group="Connections from corners to 120"),
  692. input.bool(false, "┏ →", inline="120", group="Connections from corners to 120"),
  693. input.bool(false, "┗ ↑", inline="120", group="Connections from corners to 120"),
  694. input.bool(false, "┗ →", inline="120", group="Connections from corners to 120"),
  695. input.bool(false, "┓ ←", inline="120", group="Connections from corners to 120"),
  696. input.bool(false, "┓ ↓", inline="120", group="Connections from corners to 120"),
  697. input.bool(false, "┛ ←", inline="120", group="Connections from corners to 120"),
  698. input.bool(false, "┛ ↑", inline="120", group="Connections from corners to 120"),
  699. input.bool(false, "┏ ↓", inline="126", group="Connections from corners to 126"),
  700. input.bool(false, "┏ →", inline="126", group="Connections from corners to 126"),
  701. input.bool(false, "┗ ↑", inline="126", group="Connections from corners to 126"),
  702. input.bool(true, "┗ →", inline="126", group="Connections from corners to 126"),
  703. input.bool(false, "┓ ←", inline="126", group="Connections from corners to 126"),
  704. input.bool(false, "┓ ↓", inline="126", group="Connections from corners to 126"),
  705. input.bool(false, "┛ ←", inline="126", group="Connections from corners to 126"),
  706. input.bool(false, "┛ ↑", inline="126", group="Connections from corners to 126"),
  707. input.bool(false, "┏ ↓", inline="132", group="Connections from corners to 132"),
  708. input.bool(false, "┏ →", inline="132", group="Connections from corners to 132"),
  709. input.bool(false, "┗ ↑", inline="132", group="Connections from corners to 132"),
  710. input.bool(false, "┗ →", inline="132", group="Connections from corners to 132"),
  711. input.bool(false, "┓ ←", inline="132", group="Connections from corners to 132"),
  712. input.bool(false, "┓ ↓", inline="132", group="Connections from corners to 132"),
  713. input.bool(false, "┛ ←", inline="132", group="Connections from corners to 132"),
  714. input.bool(false, "┛ ↑", inline="132", group="Connections from corners to 132"),
  715. input.bool(false, "┏ ↓", inline="138", group="Connections from corners to 138"),
  716. input.bool(false, "┏ →", inline="138", group="Connections from corners to 138"),
  717. input.bool(false, "┗ ↑", inline="138", group="Connections from corners to 138"),
  718. input.bool(false, "┗ →", inline="138", group="Connections from corners to 138"),
  719. input.bool(false, "┓ ←", inline="138", group="Connections from corners to 138"),
  720. input.bool(false, "┓ ↓", inline="138", group="Connections from corners to 138"),
  721. input.bool(false, "┛ ←", inline="138", group="Connections from corners to 138"),
  722. input.bool(false, "┛ ↑", inline="138", group="Connections from corners to 138"),
  723. input.bool(true, "┏ ↓", inline="144", group="Connections from corners to 144"),
  724. input.bool(true, "┏ →", inline="144", group="Connections from corners to 144"),
  725. input.bool(true, "┗ ↑", inline="144", group="Connections from corners to 144"),
  726. input.bool(true, "┗ →", inline="144", group="Connections from corners to 144"),
  727. input.bool(false, "┓ ←", inline="144", group="Connections from corners to 144"),
  728. input.bool(false, "┓ ↓", inline="144", group="Connections from corners to 144"),
  729. input.bool(false, "┛ ←", inline="144", group="Connections from corners to 144"),
  730. input.bool(false, "┛ ↑", inline="144", group="Connections from corners to 144")))
Advertisement
Add Comment
Please, Sign In to add comment