//----------------------------------------------------------------
// freezegun.def
//
// Copyright 2002-2004 Raven Software
//----------------------------------------------------------------

export hyperblaster
{
	options -prefix HYPR_BLASTER_ -scale .4 -keep barrel 
	//-keep flashlight -parent lft_wrst body	

	addoptions -skipmesh rt_strogg_arm_mesh 
	addoptions -skipmesh lft_strogg_arm_mesh 

	mesh	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_idle.ma 		-dest models/weapons/hyperblaster/mesh
	anim	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_idle.ma 		-dest models/weapons/hyperblaster/idle
	anim	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_fire.ma 		-dest models/weapons/hyperblaster/fire
	anim	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_raise.ma		-dest models/weapons/hyperblaster/raise
	anim	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_lower.ma		-dest models/weapons/hyperblaster/lower
	anim	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_reload.ma		-dest models/weapons/hyperblaster/reload
}

export hyperblaster_strogg
{
	options -prefix HYPR_BLASTER_ -scale .4 -keep barrel 
	addoptions -skipmesh rt_arm_mesh 
	addoptions -skipmesh lft_arm_mesh 
	mesh	work/models/weapons/marine_hyper_blaster/animations/hyper_blaster_idle.ma 		-dest models/weapons/hyperblaster/mesh_strogg
}

export hyperblaster
{
	options -prefix PLAYER_HB_ -scale .4 -keep muzzle_flash ATTACHER -sourcedir work/models/characters/marine/multiplayer -destdir models/weapons/hyperblaster/world -rename ATTACHER origin -clearorigin
	mesh	hyperblaster_idle.ma			-dest hyperblaster
	anim	hyperblaster_idle.ma			-dest idle
}

entityDef viewStyle_shouldered_hyperblaster {
	"viewoffset"				"-6.75 2.5 1.5"
	"viewangles"				"-1.6 2 6.2"
}

entityDef viewStyle_q3_hyperblaster {
	"viewoffset"				"-5.4 0.6 1.5"
  	"viewangles"				"-1.6 2.5 6.2"
}

//--------------------------------------------------------------------------------------------------------------------
// Weapon Definition
//--------------------------------------------------------------------------------------------------------------------

entityDef weapon_freezegun
{
	"editor_menu"				"pickup"
	"editor_color"				".3 .3 1"
	"editor_mins"				"-16 -16 0"
	"editor_maxs"				"16 16 32"

	"editor_usage"				"FreezeGun"

	"spawnclass"				"idItem"
	"weaponclass"				"rvWeaponFreezeGun"
	"size"						"32 32 32"
  	"model_view"				"weapon_freezegun_view"
  	"model_view_strogg"			"weapon_freezegun_view_strogg"
//	"model_world"				"weapon_freezegun_world"
	"model_world"				"weapon_hyperblaster_world"
	"model"						"models/weapons/freezegun/freezegun_world.ase"
	"def_dropItem"				"weapon_freezegun"
	"def_projectile"			"projectile_freezegun"

	"joint_attach"				"HB_ATTACHER"
	"joint_view_guiLight"		"body"
	"joint_view_flash"			"barrel"
	"joint_world_flash"			"muzzle_flash"

	"mtr_crosshair"				"gfx/guis/crosshairs/crosshair_blaster"
	"crosshairOffsetX"			"0"
	"crosshairOffsetY"			"0"

	"fireRate"					"0.1"
	"spread"					"12"
	"spread_mp"					"0"

	"inv_weapon"				"weapon_freezegun"
	"inv_item"					"1"
	"inv_icon"					"gfx/guis/hud/icons/item_freeze.tga"
	"inv_name"					"Freeze Gun"	

	"weaponname"				"FreezeGun"
	"ammoType"					"ammo_freezegun"
	"inv_start_ammo_freezegun"	"35"
	"ammoRegenStep"				"5"
	"ammoRegenTime"				"200"
	"clipSize"					"0"
	"ammoRequired"				"1"										// ammo is handled in the script file
	"gui"						"guis/weapons/hyperblaster_ammo.gui"
	"mtr_icon"					"gfx/guis/hud/icons/gun_freezegun"
	
	//"muzzle_kick_time"			"0.1"
	//"muzzle_kick_maxtime"		"0.15"
	//"muzzle_kick_angles"		"-1 0 0"
	//"muzzle_kick_offset"		"1 .15 0"

	//"recoilTime"				"100"
	//"recoilAngles"				"1 0 0"
	
	//"mtr_flashShader"			"lights/muzzleflash"
	//"flashColor"				"0.7 0.8 1"
	//"flashRadius"				"200"
	//"flashPointLight"			"1"
	//"flashTime"					".1"
	//"flashViewOffset"			"15 -2 5"

	"mtr_guiLightShader"		"lights/viewWeaponGuiLight"
	"glightRadius"				"1.3"
	"glightOffset"				"0 2 0"

	"snd_quaddamage"			"weapon_quaddamage_fire"
	"snd_acquire"				"pickup_weapon"
	"snd_noAmmo"				"weapon_hyperblaster_dryfire"

 	"fx_muzzleflash"			"effects/weapons/freezegun/freeze_core.fx"
 	"fx_muzzleflash_world"		"effects/weapons/freezegun/freeze_core.fx"
	"fx_respawn"				"effects/mp/itemrespawn.fx"

	"def_viewStyle"				"viewStyle_q3_hyperblaster"
	"def_viewStyle1"			"viewStyle_shouldered_hyperblaster"
	
	"weaponAngleOffsetAverages" "10"
	"weaponAngleOffsetScale" 	".05"
	"weaponAngleOffsetMax"		"1"
	"weaponOffsetTime"			"600"
	"weaponOffsetScale"			"0.001"

	"foreshorten"				".65"
	"hidesurface"				"models/weapons/hyperblaster/battery1"

	"net_syncPhysics"			"1"
	
	"def_mod1"					"wpmod_freezegun_ammo"
}

entityDef weapon_freezegun_mp
{
	"inherit"				"weapon_freezegun"
	"clipsize"				"0"
	"editor_ignore"				"1"
	"inv_icon"				"gfx/guis/hud/icons/item_freezegun_colored"
	"triggerSize"				"32"
	
	"muzzle_kick_time"			"0"
	"muzzle_kick_maxtime"			"0"
	"muzzle_kick_angles"			"0 0 0"
	"muzzle_kick_offset"			"0 0 0"
	"recoilTime"				"0"
	"recoilAngles"				"0 0 0"
	
	"respawn_Team DM"			"30"
	"respawn_Tourney"			"15"

}

entityDef moveable_item_freezegun
{
	"inherit"					"weapon_freezegun"

	"editor_rotatable"			"1"
	
	"itemclipmodel"					"models/weapons/hyperblaster/w_hb_clip.lwo"

	"spawnclass"				"idMoveableItem"
	"mass"					"3000"
	"density"					"0.05"
	"friction"					"0.2"
	"bouncyness"				"0"
}

//--------------------------------------------------------------------------------------------------------------------
// Models
//--------------------------------------------------------------------------------------------------------------------

model weapon_freezegun_view
{
	mesh						models/weapons/freezegun/mesh.md5mesh
	
	skin						skins/weapons/hyperblaster/nobounce
	
	anim idle 					models/weapons/freezegun/mesh.md5anim
	anim fire 					models/weapons/freezegun/mesh.md5anim	
	{
		frame 1					sound_weapon	freezegun_tempfiresound
//		frame 1					sound_item		weapon_hyperblaster_fire_stereo
	}
	anim reload 				models/weapons/freezegun/mesh.md5anim	
	{
		frame 1					sound_weapon	weapon_hyperblaster_cell_out
		frame 5				sound_item		weapon_hyperblaster_cell_in
		frame 5				sound_weapon	weapon_hyperblaster_close
	}
	anim raise					models/weapons/freezegun/mesh.md5anim
	anim putaway				models/weapons/freezegun/mesh.md5anim
	{
		frame 1					sound_weapon	weapon_switch
	}
}

model weapon_freezegun_view_strogg
{
	inherit						weapon_freezegun_view
	mesh						models/weapons/freezegun/mesh.md5mesh
}

model weapon_freezegun_world 
{
	mesh						models/weapons/freezegun/mesh.md5mesh
	anim idle					models/weapons/freezegun/mesh.md5anim
}

//--------------------------------------------------------------------------------------------------------------------
// Mods
//--------------------------------------------------------------------------------------------------------------------

//--------------------------------------------------------------------------------------------------------------------
// Projectile
//--------------------------------------------------------------------------------------------------------------------

entityDef damage_freezegun
{
	"inherit"					"damage_blaster"
	"damage"					"2"
	
	"knockback"					"0"
	"fx_wound"					"effects/wounds/energy.fx"
	"bleed"						"0"
	"pain"						"stream"
	"filter_freeze"				"1"
}

entityDef damage_freezegun_mp
{
	"inherit"				"damage_freezegun"
	"damage"					"2"
}


entityDef damage_freezegun_splash
{
	"damage"					"2"
	"gib"						"0"
	"radius"					"16"
	"filter_freeze"				"1"
}

entityDef damage_freezegun_splash_mp
{
	"inherit"				"damage_freezegun_splash"
}


entityDef projectile_freezegun
{
	"inherit"					"projectile_blaster"

	"size"						"3 3 3"
	"cone"						"3"
	"clipmask_largeshot"		"0"
	"def_damage"				"damage_freezegun"
	
	"speed"						"3100"
	"orient_towards_motion"		"1"

	"fuse"						"0.16"							
	"detonate_on_fuse"			"1"
	"detonate_on_death"			"0"
	"detonate_on_world"			"1"
	"detonate_on_actor"			"1"
	"def_splash_damage"			"damage_freezegun_splash"
	"freezeEnemies"				"1"

	"fx_impact"						"effects/weapons/freezegun/impact_default.fx"
	//"fx_impact"						""
	"fx_fly"						""
	//"fx_impact_concrete"			"effects/weapons/hyperblaster/impact_concrete.fx"
	//"fx_impact_rock"				"effects/weapons/hyperblaster/impact_concrete.fx"
	//"fx_impact_glass"				"effects/weapons/hyperblaster/impact_glass.fx"					
	//"fx_impact_bpglass"			"effects/weapons/hyperblaster/impact_bpglass.fx"
	//"fx_impact_electronics"		"effects/weapons/hyperblaster/impact_electronics.fx"	
	//"fx_impact_flesh"				"effects/weapons/hyperblaster/impact_flesh.fx"
	//"fx_impact_monstermetal"		"effects/weapons/hyperblaster/impact_flesh.fx"	
	//"fx_trail"					""
	//"fx_impact_mp"				"effects/weapons/hyperblaster/impact_default_mp.fx"
	//"fx_impact_concrete_mp"		"effects/weapons/hyperblaster/impact_default_mp.fx"
	//"fx_impact_rock_mp"			"effects/weapons/hyperblaster/impact_default_mp.fx"
	//"fx_impact_glass_mp"			"effects/weapons/hyperblaster/impact_default_mp.fx"
	//"fx_impact_bpglass_mp"		"effects/weapons/hyperblaster/impact_default_mp.fx"
	//"fx_impact_electronics_mp"	"effects/weapons/hyperblaster/impact_default_mp.fx"
}

entityDef projectile_freezegun_mp
{
	"inherit"					"projectile_freezegun"
	"def_splash_damage"			"damage_freezegun_splash_mp"	
}

entityDef wpmod_freezegun_ammo
{
	"weapon"					"weapon_freezegun"
	"ammoRequired"				"0"
}

entityDef weaponmod_freezegun_ammo
{
	"editor_color"				".3 .3 1"
	"editor_mins"				"-16 -16 0"
	"editor_maxs"				"16 16 32"
	"editor_menu"				"pickup"
	"editor_usage"				"Ammo mod for the freeze gun"

	"spawnclass"				"idItem"
	"size"						"32 32 32"
	"inv_weaponmod"				"wpmod_freezegun_ammo"
	"inv_item"					"1"
	"model"						"models/items/ammo/ammo_box.lwo"
}
