' ******************************* ' SET TABS AT 8 ' ' DTL: dtl.wdf ' ******************************* ' ************************************************************ ' Version, layout limits and simulator angle ' ************************************************************ #Version, 3 #Limits, 28, 72, 30, 130 #SimAngle, 0 #MinDelay, 0 #MaxDelay, 0 ' ************************************************************ ' Information displayed when layout is loaded ' ************************************************************ #Info, DTL: Down The Line for DryFire Version 3 onwards #Info, #Info, Single trap oscillating 22 degrees either side of the centre line. #Info, #Info, 5 stands 3 yards apart and with front of stand 16 yards from trap (centre of stand is 16.5 yards from trap). ' ************************************************************ ' Fonts, messages, colours, background ' ************************************************************ font "Arial","SEB" as 1 'Define Arial as font 1 font "Times New Roman","REB" as 2 'Define Times as font 2 font 1 'Default font - Arial Ad1$="Krieghoff": Ad1Font=2 'First ad text and font Ad2$="Perazzi": Ad2Font=1 'Second ad text and font rgb 128, 128, 128 as 0 '0 Grey - for fog rgb 255, 0, 0 as 1 '1 Red rgb 29, 207, 33 as 2 '2 Green rgb 0, 0, 255 as 3 '3 Blue rgb 228, 253, 60 as 4 '4 Yellow rgb 128, 128, 128 as 5 '5 Grey rgb 128, 64, 0 as 6 '6 Brown rgb 255, 102, 51 as 7 '7 Orange rgb 228, 253, 60 as 8 '8 Sun rgb 0, 128, 0 as 9 '9 Grass rgb 255,255,255 as 10 '10 White for textured sky rgb 60,60,60 as 11 '11 Dark grey for shadows rgb 0,0,0 as 12 '12 Black texture "SKY128" as 1 'Texture file used for sky texture "BROWN" as 2 'Texture used for shot string texture "GRASS" as 3 'Grass texture 1 'Select sky texture shadow 11 'Grey shadows north 0 'North is set at 0 degrees - straight ahead clip 0.1,1000, 0.01,10**7 light 180,20,10**5, 0.5,1,0.5,1, 0.1,0.1 ;Draw sky Push : Texture 1 : Colour 10 : View 2 Set Effects off, Background on, Texture on, Ambient on Scale 10**5 : Sphere 0,0,1 : Pop ;Draw sun Push : Set Effects off, Background on, Ambient on : Colour 8 Scale 3000 : Move Light : Sphere -1,0,3 : Pop ;Draw ground Push : Set Effects off, Background on, Ambient on : Colour 9 Scale 1000 : Polygon 5 : Scale 1000 : Polygon 5 : Pop ' Traps 'Distance 48m with height at 9.14m set to 2.74m. Height does not vary. Spread angle 22 degrees trap 1, "DTL/Standard", 50,52,0, 50,100,0, 9.14,2.74,2.74,2.74, 22 , 0 'reset: colour 6: scale 3,2.4,0.8: move 48.5,50.8,0: cube reset: colour 6 'Brown trap house push: scale 3,2.4,0.05: move 48.5,50.8,.8: cube: pop 'Top push: scale 3,0.05,.8: move 48.5,50.8,0: cube: pop 'Back push: scale .05,2.4,.8: move 48.5,50.8,0: cube: pop 'Left side push: scale .05,2.4,.8: move 48.5+3-.05,50.8,0: cube: pop 'Right side ' Stands x=44.4661: y=37.9639: a=68.4825 #Stand, DTL 1, 44.4661, 37.9639, 0, 68.4825 reset: colour 2: scale .9144,.9144, 0: rotz -(90-a): move x, y, 0: polygon 4 'DTL 1 reset: colour 3: scale .3,.3,.5: move x-1, y-2 ,0: view 2: cylinder 24,1,1,0 'Waste bin x=47.1837: y=37.1776: a=79.2412 #Stand, DTL 2, 47.1837, 37.1776, 0, 79.2412 reset: colour 2: scale .9144,.9144, 0: rotz -(90-a): move x, y, 0: polygon 4 'DTL 2 reset: colour 3: scale .3,.3,.5: move x-1, y-2 ,0: view 2: cylinder 24,1,1,0 'Waste bin x=50: y=36.9124: a=90 #Stand, DTL 3, 50.000, 36.9124, 0, 90 reset: colour 2: scale .9144,.9144, 0: rotz -(90-a): move x, y, 0: polygon 4 'DTL 3 reset: colour 3: scale .3,.3,.5: move x, y-2 ,0: view 2: cylinder 24,1,1,0 'Waste bin x=52.8165: y=37.1776: a=100.7588 #Stand, DTL 4, 52.8165, 37.1776, 0, 100.7588 reset: colour 2: scale .9144,.9144, 0: rotz -(90-a): move x, y, 0: polygon 4 'DTL 4 reset: colour 3: scale .3,.3,.5: move x+1, y-2 ,0: view 2: cylinder 24,1,1,0 'Waste bin x=55.5339: y=37.9639: a=111.5175 #Stand, DTL 5, 55.5339, 37.9639, 0, 111.5175 reset: colour 2: scale .9144,.9144, 0: rotz -(90-a): move x, y, 0: polygon 4 'DTL 5 reset: colour 3: scale .3,.3,.5: move x+1, y-2 ,0: view 2: cylinder 24,1,1,0 'Waste bin ' #Target format: name, stand, first trap, second trap, second shot trap, type (0=single, 1=simultaneous, 2:on-report), viewing angle #Target, "DTL stand 1", 1 , 1 , 0 , 1 , 0, 68.4825 #Target, "DTL stand 1", 1 , 1 , 0 , 1 , 0, 68.4825 #Target, "DTL stand 1", 1 , 1 , 0 , 1 , 0, 68.4825 #Target, "DTL stand 1", 1 , 1 , 0 , 1 , 0, 68.4825 #Target, "DTL stand 1", 1 , 1 , 0 , 1 , 0, 68.4825 #Target, "DTL stand 2", 2 , 1 , 0 , 1 , 0, 79.2412 #Target, "DTL stand 2", 2 , 1 , 0 , 1 , 0, 79.2412 #Target, "DTL stand 2", 2 , 1 , 0 , 1 , 0, 79.2412 #Target, "DTL stand 2", 2 , 1 , 0 , 1 , 0, 79.2412 #Target, "DTL stand 2", 2 , 1 , 0 , 1 , 0, 79.2412 #Target, "DTL stand 3", 3 , 1 , 0 , 1 , 0, 90 #Target, "DTL stand 3", 3 , 1 , 0 , 1 , 0, 90 #Target, "DTL stand 3", 3 , 1 , 0 , 1 , 0, 90 #Target, "DTL stand 3", 3 , 1 , 0 , 1 , 0, 90 #Target, "DTL stand 3", 3 , 1 , 0 , 1 , 0, 90 #Target, "DTL stand 4", 4 , 1 , 0 , 1 , 0, 100.7588 #Target, "DTL stand 4", 4 , 1 , 0 , 1 , 0, 100.7588 #Target, "DTL stand 4", 4 , 1 , 0 , 1 , 0, 100.7588 #Target, "DTL stand 4", 4 , 1 , 0 , 1 , 0, 100.7588 #Target, "DTL stand 4", 4 , 1 , 0 , 1 , 0, 100.7588 #Target, "DTL stand 5", 5 , 1 , 0 , 1 , 0, 111.5175 #Target, "DTL stand 5", 5 , 1 , 0 , 1 , 0, 111.5175 #Target, "DTL stand 5", 5 , 1 , 0 , 1 , 0, 111.5175 #Target, "DTL stand 5", 5 , 1 , 0 , 1 , 0, 111.5175 #Target, "DTL stand 5", 5 , 1 , 0 , 1 , 0, 111.5175 ' Other features reset: colour 5: scale 30,1,0: move 50,26,0: polygon 4 'Path reset: colour 6: scale .7,.7,.1: rotx 60: move 50,23,.6: textcentre "DTL" reset: colour 1: scale .4,.4,.1: rotx 60: move 50,22.9,.2: textcentre "Sponsored by DryFire" reset: colour 4: scale .25,14,3: move 28.36,30.83,0: cube 'Left safety wall reset: colour 1: scale 1,1.8,.2: rotx 90: rotz 90: move 28.36+.45,30.83+6,1 font Ad1Font: textcentre Ad1$ reset: colour 4: scale .25,14,3: move 71.39,30.83,0: cube 'Right safety wall reset: colour 1: scale 1,1.8,.2: rotx 90: rotz -90: move 71.39-.2,30.83+6,1 font Ad2Font: textcentre Ad2$ reset: colour 1: scale .2,.2,1: move 49.9,99.9,0: cube 'DTL distance marker reset: scale 6,6,8: movex 20: movey 106: Tree 0.3, 0.5, 0.7 'Small tree movex 8: Tree 0.3, 0.5, 0.7 'Small tree movex -14: movey -6: Tree 0.3, 0.5, 0.7 'Small tree movex 10: Tree 0.3, 0.5, 0.7 'Small tree reset: scale 6,6,10 : movex 21: movey 114: Tree 0.3, 0.5, 0.7 'Medium tree movex -6: Tree 0.3, 0.5, 0.7 'Medium tree reset: scale 6,6,12 : movex 24: movey 110: Tree 0.3, 0.5, 0.7 'Large tree reset: scale 6,6,8: movex 80: movey 106: Tree 0.3, 0.5, 0.7 'Small tree movex 8: Tree 0.3, 0.5, 0.7 'Small tree movex -14: movey -6: Tree 0.3, 0.5, 0.7 'Small tree movex 10: Tree 0.3, 0.5, 0.7 'Small tree reset: scale 6,6,10 : movex 79: movey 114: Tree 0.3, 0.5, 0.7 'Medium tree movex -6: Tree 0.3, 0.5, 0.7 'Medium tree reset: scale 6,6,12 : movex 76: movey 110: Tree 0.3, 0.5, 0.7 'Large tree ' ************************************************************ ' Standard routines and functions - DO NOT EDIT ' ************************************************************ Function DrawStar Sects, Segs, Angle, Length { enter colour 0 font "Comic Sans MS", "Cursive Bold 2D" as 1 : font 1 local i=0, j, b, p, FontScale=1, BarRadius=0.2 local a=-Sects*Angle/2, x=sin(a)*Length, y=cos(a)*Length push : scale BarRadius,BarRadius,1 : roty a : pre push : scalez Length*Segs : post while i<=Sects 'Draw sector dividers { cylinder 6,1,1,1 : roty Angle : i=i+1 } a=-Sects*Angle/2 : x=sin(a)*Length : y=cos(a)*Length pop : scalez 2*Length*sin(Angle/2) : post : roty 90+Angle/2 : i=1 while i<=Segs 'Draw segment dividers { move x,0,y : push : j=0 while j 0 { Platform Size*1.5, Height ' Platform } movez Height if Size > 0 { SafetyFence 1, Size, .1 ' Safety fence } exit } Function DrawTrap Size, Height ' Size is platform size (square) ' Height must be a multiple of Size (or zero) { enter push: colour 2: scale Size,Size,.2: move 0-Size/2,0-Size/2,Height: cube: pop ' Platform push: colour 1: scale 1,1,1: move -.5,-.5,Height+.2: cube: pop ' Trap on platform if Height > 0 { push: colour 4: scale .5,.5,.5: sphere 0,0,3: pop ' Find me 1 push: colour 3: scale .2,.2,.2: sphere -1,0,3: pop ' Find me 2 t=.04: q=0 while q < Height/Size { push: fz=q*Size: scale Size: Layer fz,Size: pop: q=q+1 ' Layers } colour 6 ' Brown ladder push scale .03,.1,Height+Size/4: move 0,-Size/2-.2,0: cube: movex .3: cube ' Ladder sides pop q=Size*q/.25+2 while q>0 { push: scale .3,.1,.03: move 0,-Size/2-.2,q*.25: cube: pop: q=q-1 ' Ladder rungs } } exit } Function Layer z,s ' Each layer of a tower { push: move 0,0,z: OpenPanel: pop ' Front push: move 0,s-s*t,z: OpenPanel: pop ' Back push: rotz 90: move 0,0,z: OpenPanel: pop ' Left push: rotz 90: move -Size+s*t,0,z: OpenPanel: pop ' Right } Function OpenPanel ' Panel with diagonals { enter push: scale 1,t,t: move -.5,-.5,0: cube: movez 1-t: cube: pop ' Bottom/top push: scale t,t,1: move -.5,-.5,0: cube: movex 1-t: cube: pop ' Sides push: scale 1.414-t-t,t,t: roty -45: move -.5+t,-.5,0: cube: pop ' Diagonal push: scale 1.414-t-t,t,t: roty 45: move -.5,-.5,1-t: cube: pop ' Diagnonal exit } Function Platform Size, Height ' Draw platform for shooter to stand on { enter push: colour 2: scale Size,Size,Height: move -Size/2,-Size/2,0: cube: pop ' Platform push colour 6: x=Height/.5-1 ' Number of steps move -Size/2,-Size/2,0 while x>0 { movex -.5 enter: scale .5, Size, x*.5: cube: exit ' Draw steps x=x-1 } pop exit } Function SafetyFence MatWidth, FenceSize, BarThickness ' Draw safety fence round shooter { enter push: colour 2: scale MatWidth*.7071, MatWidth*.7071, 0: polygon 4: pop ' Shooting mat move -FenceSize/2, FenceSize/2, 0 enter colour 5: scale BarThickness, BarThickness, FenceSize x=0 while x<2 ' Sides { push movey -FenceSize*x: cube ' Left vertical edge movex FenceSize-BarThickness: cube ' Right vertical edge roty 90: movez FenceSize: cube ' Bottom bar movez FenceSize/4: cube ' Lower bar movez FenceSize/4: cube ' Middle bar movez FenceSize/4: cube ' Higher bar movez FenceSize/4: cube ' Top bar x=x+1 pop } rotx 90 ' Front bars movex FenceSize-BarThickness: cube ' Bottom bar movez FenceSize/4: cube ' Middle bar colour 1: set non-obscuring on: movez FenceSize/4: cube ' Top bar exit exit } Function DrawGate ' Gate with four panels and side posts { enter push: move -.5,.5,0: OpenPanel: movex 1: OpenPanel: movez 1: OpenPanel: movex -1: OpenPanel: pop p=.2 push: scale p,p,2.2: move -1-p,-p/2,0: cube: movex 2+p: cube: pop exit } Function Wall x, y, l, w, h, a, f, s, t$ ' Wall: x-centre, y-centre, length, width, height, angle, font, size, text { enter b=Atan(w/l): d=(w/Sin(b))/2: x1=x-d*Cos(a+b): y1=y-d*Sin(a+b) w1=w/2+s/10: x2=x+w1*sin(a): y2=y-w1*cos(a) push: colour 4: scale l,w,h: rotz a: move x1, y1, 0: cube: pop push: colour 1: scale s,s,s/10: rotx 90: rotz a: move x2,y2, (h-s)/2: font f: textcentre t$: pop exit } Function Tree TrunkWidth,TrunkHeight,TrunkTaper ' Tree drawing function { enter push scale TrunkWidth/2,TrunkWidth/2,TrunkHeight : colour 6 cylinder 10,TrunkTaper,1,0 pop scale 0.5,0.5,1-TrunkHeight : movez TrunkHeight : colour 2 cone 16,1 exit }