Ricochet.fgd

From Valve Developer Community
Revision as of 01:34, 25 July 2022 by Veinhelm (talk | contribs) (Fix FGD)
Jump to navigation Jump to search
Ricochet Level Creation
This is a FGD (Forge Game Data) file used to define all of the entities of a game for a map editor (such as Hammer).
To add a FGD file to the map editor, copy the following text into a text editor such as Windows Notepad, Notepad++ Notepad++ or Visual Studio Code Visual Studio Code, and save it with "save as type" being "all files" and .fgd appended to the file name. Then open your map editor and add the FGD to your game configuration (Example for HL:S).
Tip.pngTip:Select the beginning of the line (usually the "//" comment) by clicking it, scroll down then hold Shift, and click at the end of the line to select all.
// Ricochet FGD file
// By SiPlus
// April 4, 2012 revision
// For Hammer 3.5
// http://developer.valvesoftware.com/wiki/Ricochet_Level_Creation
// Requires Half-Life FGD
// Fixed by Veinhelm
@SolidClass = worldspawn : "World entity"
[
	message(string) : "Map Description / Title"
	skyname(string) : "environment map (cl_skyname)" : "disc"
	sounds(integer) : "CD track to play" : 1
	light(integer) : "Default light level"
	WaveHeight(string) : "Default Wave Height"
	MaxRange(string) : "Max viewable distance" : "4096"
	chaptertitle(string) : "Chapter Title Message"
	startdark(choices) : "Level Fade In" : 0 =
	[
		0 : "No"
		1 : "Yes"
	]
	gametitle(choices) : "Display game title" : 0 = 
	[
		0 : "No"
		1 : "Yes"
	]
	newunit(choices) : "New Level Unit" : 0 = 
	[
		0 : "No, keep current"
		1 : "Yes, clear previous levels"
	]
	mapteams(string) : "Map Team List"
	defaultteam(choices) : "Default Team" : 0 = 
	[
		0 : "Fewest Players"
		1 : "First Team"
	]
	no_arena(choices) : "Game mode" : 1 =
	[
		0 : "Arena"
		1 : "Deathmatch"
	]
]

//
// BaseClasses
//

@BaseClass = Appearflags
[
	spawnflags(Flags) =
	[
		2048 : "Not in Deathmatch" : 0
	]
]

@BaseClass = Angles
[
	angles(string) : "Pitch Yaw Roll (Y Z X)" : "0 0 0" : "Sets the pitch (up / down), yaw (left / right) and roll (bank) respectively. The compass in Jackhammer corresponds to Yaw. The settings are not always (or not all) used."
]

@BaseClass size(0 0 0, 32 32 32) color(80 0 200) base(Appearflags) = Ammo []

@BaseClass = Targetname 
[ 
	targetname(target_source) : "Name" : : "Property used to identify entities."
]
@BaseClass = Target 
[ 
	target(target_destination) : "Target" : : "When an entity is activated, it triggers the entity with the name specified by Target."
]

@BaseClass size(-16 -16 0, 16 16 32) color(0 0 200) base(Targetname, Appearflags, Angles) = Weapon []

@BaseClass base(Target) = Targetx 
[
	delay(string) : "Delay before trigger" : "0" : "Usually the time in seconds before an entity should trigger its target (after being triggered itself). Under other SmartEdit names, delay might also be the time to wait before performing some other action."
	killtarget(target_destination) : "KillTarget" : : "When an entity is triggered, it will remove from the game the entity specified by this property."
]

@BaseClass base(Appearflags, Angles) flags(Angle) size(-16 -16 -36, 16 16 36) color(0 255 0) offset(0 0 36) = PlayerClass []

// Ricochet stuff

@PointClass base(PlayerClass) = info_player_start []
@PointClass base(PlayerClass) studio("models/player/male/male.mdl") = info_player_deathmatch
[
	target(target_destination) : "Target"
	master(string) : "Master"
]

@PointClass base(Angles) = info_ricochet []
@PointClass base(PlayerClass) studio("models/head.mdl") = info_player_spectator
[
	target(target_destination) : "Target"
	master(string) : "Master"
]
@PointClass size(-16 16 0,16 16 16) base(PlayerClass, Targetname) studio("models/head.mdl") = info_teleport_destination []
@PointClass size(-16 -16 -16, 16 16 32) base(Weapon, Targetx) studio("models/pow_visual.mdl") = item_powerup []
@SolidClass = trigger_discreturn []
@SolidClass = trigger_fall []
@SolidClass base(Target) = trigger_jump
[
	height(integer) : "Height" : 128
	target(target_destination) : "Target"
]