This is the mail archive of the xconq7@sourceware.cygnus.com mailing list for the Xconq project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Early version of GDL for Western Game


Hi, all.

Here is an early draft of the GDL I'm working on
for my Western game.  Any comments?

Steve Schacher



--== Sent via Deja.com http://www.deja.com/ ==--
Before you buy.
(game-module "western"
	(title "western gunfighting")
	(blurb "Basic module for defining character behavior")
)

;;;;;;;;;;;;;;;;;
; Game Settings ;
;;;;;;;;;;;;;;;;;

(set grid-color "black")
(set see-all true)
(set units-may-go-to-sleep false)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; World and Terrain Definitions ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(area 15 15)

(terrain-type plains
	(image-name "plains")
	
)

;;;;;;;;;;;;;;;;;;;;;;;;
; Material Definitions ;
;;;;;;;;;;;;;;;;;;;;;;;;

(material-type cocked-weapon)
(material-type bullets)

;;;;;;;;;;;;;;;;;;;;
; Unit Definitions ;
;;;;;;;;;;;;;;;;;;;;

(unit-type man 
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(acp-to-move 2)
	(range 15)
	(start-with 1)
)
(unit-type man-with-aim-1
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-2
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-3
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-4
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-5
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-6
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-7
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)
(unit-type man-with-aim-8
	(image-name "man")
	(acp-per-turn 1)
	(free-acp 0)
	(acp-min -1)
	(acp-to-fire 1)
	(speed 0)			; aiming person cannot move
	(range 15)
)

;;;;;;;;;;;;;;;
; Unit Tables ;
;;;;;;;;;;;;;;;

(table unit-storage-x
	(u* cocked-weapon 1)
	(u* bullets 6)
 )

(table acp-to-change-type
	(man man-with-aim-1 2)
	(man-with-aim-1 man-with-aim-2 2) 
	(man-with-aim-2 man-with-aim-3 2) 
	(man-with-aim-3 man-with-aim-4 2) 
	(man-with-aim-4 man-with-aim-5 2) 
	(man-with-aim-5 man-with-aim-6 2) 
	(man-with-aim-6 man-with-aim-7 2) 
	(man-with-aim-7 man-with-aim-8 2)
	(man-with-aim-1 man 1) 
 	(man-with-aim-2 man 1) 
	(man-with-aim-3 man 1) 
	(man-with-aim-4 man 1) 
	(man-with-aim-5 man 1) 
	(man-with-aim-6 man 1) 
	(man-with-aim-7 man 1) 
	(man-with-aim-8 man 1) 
)

;;;;;;;;;;;;;;;;;;;
; Material Tables ;
;;;;;;;;;;;;;;;;;;;

(table material-per-production
	(u* cocked-weapon 0)
	(man cocked-weapon 1)	; must change-type back to man before cocking
)

(table acp-to-produce
	(u* cocked-weapon 0)
	(man cocked-weapon 2)	; must change-type back to man before cocking
	(man bullets 2)		; must change-type back to man before loading
)

(table unit-initial-supply
	(man cocked-weapon 1)
	(man bullets 6)
)

;;;;;;;;;;;;;;;;;
; Combat Tables ;
;;;;;;;;;;;;;;;;;

(table hit-chance   ; will replace with realistic numbers later
	(man u* 10)
	(man-with-aim-1 u* 20)
	(man-with-aim-2 u* 30)
	(man-with-aim-3 u* 40)
	(man-with-aim-4 u* 50)
	(man-with-aim-5 u* 60)
	(man-with-aim-6 u* 70)
	(man-with-aim-7 u* 80)
	(man-with-aim-8 u* 90)
)

(table material-to-fire
	(u* cocked-weapon 1)	; must have a cocked weapon
	(u* bullets 1)		; weapon must be loaded
)

(table consumption-per-fire
	(u* cocked-weapon 1)	; gun uncocks after being fired
	(u* bullets 1)		; a bullet is consumed after firing
)

(table acp-to-attack
	(u* u* 2)
)

(table damage
	(u* u* 1)
)

;;;;;;;;;;;;;;;
; Scorekeeper ;
;;;;;;;;;;;;;;;

(scorekeeper
	(do last-side-wins)
)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]