#include "ui/menudef.h"

{
  assetGlobalDef {
    	cursor "ui/assets/3_cursor2"	
    	gradientBar "ui/assets/gradientbar2.tga"	
    	fadeClamp 1.0	
	fadeCycle 1	
	fadeAmount 0.1

	shadowX  5	
	shadowY  5	
	shadowColor 0.1 0.1 0.1 0.25	

   	font "fonts/font" 24
    	smallFont "fonts/smallfont" 16	
    	bigFont "fonts/bigfont" 48	
  }

//	Notification AREA	
menuDef {
	name "msgsArea"
	fullScreen MENU_FALSE
	visible MENU_TRUE
	rect 470 4 64 36

    itemdef {
	name tourneyMsg
   	rect 0 0 32 32
    	style 1
        background "sprites/foe2.png"
   	visible 1
        ownerdrawflag CG_SHOW_IF_NOTICE_PRESENT
	decoration
	backcolor 1 1 1 1.0

	}
    itemdef {
	name gotMsg
   	rect 34 0 32 32
    	style 1
        background "sprites/balloon4.png"
   	visible 1
        ownerdrawflag CG_SHOW_IF_MSG_PRESENT
	decoration
	backcolor 1 1 1 1.0
	}
}

menuDef {
    	name "ScoreFrame"
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
    	rect 608 358 32 256
        ownerdrawflag CG_SHOW_IF_CHAT_VISIBLE

//Score Frame BG, can be scaled wider if needed to make more room for names
	itemDef {
     	name "scoreboxl"
	rect 0 0 32 64 
	visible 1
   	decoration
	backcolor 1 1 1 0.8
	style 1
	background "ui/assets/hud/scoreboxl.tga"
	}

//GAMETYPE ICON
itemDef {
	name "gameType"
	rect 6 7 19 19
	style 0
	backcolor 1 1 1 1
	ownerdraw CG_GAME_TYPE_ICON
	visible 1
	decoration
	}	
//WIN VALUE
	itemDef {
      	name "WinLimit"
      	textalign 1
        rect 7 37 40 12
	visible 1
    	decoration
	forecolor 0 0 0 1
	textscale .26
	ownerdraw CG_CAPFRAGLIMIT 
	}
}


menuDef {
	name "Scoreboxes1"
	rect 0 18 640 480
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
	ownerdrawflag CG_SHOW_ANYTEAMGAME

	itemDef {
		rect 610 418 28 16
		visible 1
	    	ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE  
		backcolor 1 0 0 0.25
		style 1
	}
	
	itemDef {
		rect 610 438 28 16
		visible 1
	    	ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE
		backcolor 0 0 1 0.25
		style 1
	}


	itemDef {
		ownerdraw CG_RED_SCORE
		rect 602 411 32 20
		visible 1
	    	ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE
		textscale 0.25
		textalign 2   //1 
		decoration
	}
	
	itemDef {
		ownerdraw CG_BLUE_SCORE
	    	ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE
		rect 602 431 32 20
		visible 1
		textscale 0.25
		textalign 2   
		decoration
	}

}


menuDef {
	name "Scoreboxes2"
	rect 0 18 640 480
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
	ownerdrawflag CG_SHOW_ANYTEAMGAME

	itemDef {
		rect 610 418 28 16
		visible 1
	 	ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		backcolor 0 0 1 0.25
		style 1
	}
	
	itemDef {
		rect 610 438 28 16
		visible 1
	 	ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		backcolor 1 0 0 0.25
		style 1
	}

	itemDef {
		rect 602 431 32 20
		ownerdraw CG_RED_SCORE
		ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		visible 1
		textscale 0.25
		textalign 2   //1 
		decoration
	}
	
	itemDef {
		rect 602 411 32 20
		ownerdraw CG_BLUE_SCORE
		ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		visible 1
		textscale 0.25
		textalign 2   //1
		decoration
	}

}


menuDef {
	name "FFaScoreboxes"
	rect 0 18 640 480
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
	ownerdrawflag CG_SHOW_ANYNONTEAMGAME


	itemDef {
		rect 610 418 28 16
		visible 1
	 	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
		backcolor 0 0 1 0.25
		style 1
	}
	
	itemDef {
		rect 610 438 28 16
		visible 1
	 	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
		backcolor 1 0 0 0.25
		style 1
	}


	itemDef {
		rect 610 418 28 16
		visible 1
	    	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE  
		backcolor 1 0 0 0.25
		style 1
	}
	
	itemDef {
		rect 610 438 28 16
		visible 1
	    	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
		backcolor 0 0 1 0.25
		style 1
	}

	itemDef {
		name "1stplace"
		ownerdraw CG_1STPLACE
		ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
		rect 617 431 30 20
		visible 1
		textscale .25
		decoration
	}

	itemDef {
		name "2ndplace"
		ownerdraw CG_PLAYER_SCORE
		ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE 
		rect 611 431 30 20
		visible 1
		textscale .25
		decoration
	}


	itemDef {
		name "1stplace"
		ownerdraw CG_2NDPLACE
		ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
		rect 617 451 30 20
		visible 1
		textscale .25
		decoration
	}

	itemDef {
		name "2ndplace"
		ownerdraw CG_PLAYER_SCORE
		ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE 
		rect 611 411 30 20
		visible 1
		textscale .25
		decoration
	}
}
	//*****AMMO*****//
	
	menuDef {
		name        "Ammo"
		fullScreen  MENU_FALSE
		visible     MENU_TRUE
		rect        105 453 99 36
		
		itemDef {
			name        "ammoIcon"
			decoration
			rect        100 -6 28 28 
			visible     1
			ownerdraw   CG_PLAYER_AMMO_ICON2D
		}
	
		itemDef {
			name          "ammoValue"
			decoration
			rect          28 10 63 12
			visible       1
			textstyle     0
			textscale     0.87
			forecolor     1 1 1 1
			ownerdraw     CG_PLAYER_AMMO_VALUE
			addColorRange -999 0 1 0 0 1
			addColorRange 1 999 1 1 1 1
		}
	}
	//*****PLAYER HEALTH*****//
	
	menuDef {
		name        "Player"
		fullScreen  MENU_FALSE
		visible     MENU_TRUE
		rect        292 453 95 36
	

		itemDef {
			name          "healtValue"
			decoration
			rect          -5 0 63 22
			visible       1
			textalign     2
			textstyle     0
			forecolor     1 1 1 1
			textscale     0.87
			ownerdraw     CG_PLAYER_HEALTH
			addColorRange -999 25 1 0.05 0.05 1
			addColorRange 26 100 1 0.8 0.02 1
			addColorRange 101 999 1 1 1 1
		}
	}
	//*****PLAYER ARMOR*****//
	
	menuDef {
    	name "ArmorFrame"
		fullScreen  MENU_FALSE
		visible     MENU_TRUE	
		rect        367 453 95 32
	
		itemDef {
			name          "armorValue"
			decoration
			rect          34 0 63 22
			visible       1
			textstyle     0	
			textscale     0.87
			textalign     0
			ownerdraw     CG_PLAYER_ARMOR_VALUE 
			addColorRange -999 0 1 1 1 0
			addColorRange 1 100 1 0.8 0.02 1
			addColorRange 101 999 1 1 1 1
		}
	}
menuDef {
    	name "Timer"
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
 
	itemDef {
		name "Team"
		textalign 1
		style 0
		rect 557 76 50 12
		visible 1
		textstyle 3
		decoration
		forecolor 1 1 1 1
		textscale .65
		ownerdraw CG_LEVELTIMER
		ownerdrawflag CG_SHOW_ANYTEAMGAME
	}

	itemDef {
		name "Duel"
		textalign 1
		style 0
		rect 557 76 50 12
		visible 1
		textstyle 3
		decoration
		forecolor 1 1 1 1
		textscale .65
		ownerdraw CG_LEVELTIMER
		ownerdrawflag CG_SHOW_ANYNONTEAMGAME
	}



	itemDef {
		name "CA_Roundtimer"
		textalign 2
		style 0
		rect 278 45 50 12
		visible 1
		textstyle 3
		decoration
		forecolor 1 0 0 1
		textscale 1
		ownerdraw CG_ROUNDTIMER
		ownerdrawflag CG_SHOW_CLAN_ARENA
	}
}

	//*****CLAN ARENA*****//
	
	menuDef {
		name        "caFrame"
		fullScreen  MENU_FALSE
		visible     MENU_TRUE
		rect        260 415 64 48
		ownerdrawflag CG_SHOW_CLAN_ARENA

		
		itemDef {
			name          "redClanPlayers"
			decoration
			ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
			ownerdraw     CG_RED_CLAN_PLYRS  
			rect          85 20 136 40
			visible       1
			textalign     ITEM_ALIGN_RIGHT
			textscale     .3
			forecolor     1 1 1 0.7
		}
		
		itemDef {
			name          "blueClanPlayers"
			decoration
			ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
			ownerdraw     CG_BLUE_CLAN_PLYRS  
			rect          30 20 32 16
			visible       1
			textalign     ITEM_ALIGN_RIGHT
			textscale     .3
			forecolor     1 1 1 0.7
		}
		
		itemDef {
			name          "redClanPlayers"
			decoration
			ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_RED
			ownerdraw     CG_RED_CLAN_PLYRS  
			rect          30 20 32 16
			visible       1
			textalign     ITEM_ALIGN_RIGHT
			textscale     .3
			forecolor     1 1 1 0.7
		}
		
		itemDef {
			name          "blueClanPlayers"
			decoration
			ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_RED
			ownerdraw     CG_BLUE_CLAN_PLYRS  
			rect          85 20 136 40
			visible       1
			textalign     ITEM_ALIGN_RIGHT
			textscale     .3
			forecolor     1 1 1 0.7
		}
		
		itemDef {
			name          "ca_vs"
   			rect          71 19 136 40
   			visible       1
			textalign     2
			textscale     .3
			forecolor     1 1 1 0.7
			decoration
			text          vs
		}
	}

/////////////////////////////////////////////////////////////////////////////////

// CA
menuDef {
	name "caFrame2"
	fullScreen MENU_FALSE
	visible MENU_TRUE
	rect 331 145 48 32
        ownerdrawflag CG_SHOW_CLAN_ARENA
        
	itemDef {
		name "1redClanPlayers_number"
		ownerdraw CG_RED_CLAN_PLYRS  
		ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
   		rect 3 281 32 16
   		visible 1
		textalign 2
		textscale .3
		forecolor 1 1 1 0.15
		decoration
	}


	itemDef {
		name "1blueClanPlayers_number"
		ownerdrawflag CG_SHOW_IF_PLYR_IS_ON_BLUE
		ownerdraw CG_BLUE_CLAN_PLYRS  
		rect -36 281 136 40
		visible 1
		textalign 2
		textscale .3
		forecolor 1 1 1 0.15
		decoration
	}


}

menuDef {
	name "FlagstatusFrame1"
	rect 580 434 60 60
	fullScreen MENU_FALSE
	visible MENU_TRUE
	ownerdrawflag CG_SHOW_CTF
	
	itemDef {
		name "redflag1"
		rect 7 2 20 16
		visible 1
		decoration
		ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE
		ownerdraw CG_RED_FLAGSTATUS
	}
	
	itemDef {
		name "blueflag1"
		rect 7 22 20 16
		visible 1
		decoration    
		ownerdrawflag CG_SHOW_IF_RED_IS_FIRST_PLACE
		ownerdraw CG_BLUE_FLAGSTATUS
	}

}

menuDef {
	name "FlagstatusFrame2"
	rect 580 434 60 60
	fullScreen MENU_FALSE
	visible MENU_TRUE
	ownerdrawflag CG_SHOW_CTF
	
	itemDef {
		name "redflag2"
		rect 7 22 20 16
		visible 1
		decoration
		ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		ownerdraw CG_RED_FLAGSTATUS
	}
	
	itemDef {
		name "blueflag2"
		rect 7 2 20 16
		visible 1
		decoration    
		ownerdrawflag CG_SHOW_IF_BLUE_IS_FIRST_PLACE
		ownerdraw CG_BLUE_FLAGSTATUS
	}

}

menuDef {
	name "scoresFrame"
	rect 580 434 60 60
	fullScreen MENU_FALSE
	visible MENU_TRUE


	itemDef {
		name "oneflagstatus"
		rect 0 10 28 20
		visible 1
		decoration                	
		ownerdraw CG_ONEFLAG_STATUS
	}
	
	itemDef {
		name "harvesterRed"
		rect 8 0 20 20
		visible 1
		bordercolor 1 1 1 1
		decoration	
		style 3
		ownerdrawflag CG_SHOW_HARVESTER                 
		background "icons/skull_red.png"
	}
	
	itemDef {
		name "harvesterBlue"
		rect 8 20 20 20
		visible 1
		bordercolor 1 1 1 .75
		decoration	
		style 3
		ownerdrawflag CG_SHOW_HARVESTER                 
		background "icons/skull_blue.png"
	}
	


}

// DM/TOURNAMENT BAR
menuDef {
    	name "SelfFrameHighlights"
    	fullScreen MENU_FALSE
    	visible MENU_FALSE	
    	rect 2 7 32 256

	itemDef {
     	name "SelfTLeft"
	rect 32 0 16 16 
	visible 1
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
	style 1
	background "ui/assets/hud/teamonl.tga"
	}

	itemDef {
     	name "SelfTMid"
	rect 48 0 115 16 
	visible 1
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
	style 1
	background "ui/assets/hud/teamonm.tga"
	}

	itemDef {
     	name "SelfTLeft"
	rect 163 0 16 16 
	visible 1
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
	style 1
	background "ui/assets/hud/teamonr.tga"
	}

	itemDef {
     	name "SelfBLeft"
	rect 605 432 16 16 
	backcolor 1 1 0 1
	visible 0
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
	style 1
	background "ui/assets/hud/teamonl.tga"
	}

	itemDef {
     	name "SelfBLeft"
	rect 621 432 16 16 
	visible 0
	backcolor 0.8 0.8 0.3 1
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
	style 0
	background "ui/assets/hud/teamonr.tga"
	}

	itemDef {
     	name "SelfBMid"
	rect -948 17 115 16 
	visible 0
   	decoration
	ownerdraw CG_TEAM_COLORIZED
	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
	style 1
	background "ui/assets/hud/teamonm.tga"
	}

}


// you can use "ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE"
// or 	"ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE" to toggle the
// score highlight on / off for the first and second place score boxes

//*****Player Pickups*****//

	//*****POWERUP*****//
	//quad, bs, regen ...

	menuDef {
		name       "powerup"
		fullScreen MENU_FALSE
		visible    MENU_TRUE
		rect       555 350 74 156
	
		itemDef {
			name      "powerupArea"
			decoration
			rect      0 0 39 26
			visible   1
			textscale 0.82
			textstyle 3
			ownerdraw CG_AREA_POWERUP
			special   0			// spacing
			align     1
		}
	}
// useable pickups


menuDef {
    	name "pickups"
    	fullScreen MENU_FALSE
    	visible MENU_TRUE
    	rect 470 467 32 64

	itemDef {
      	name "playeritem"
        rect 3 -16 20 20
	visible 1
	decoration
	ownerdraw CG_PLAYER_ITEM  
	}
	itemDef {
      	name "CTFPOWERUP"
        rect 3 5 20 20
	visible 1
	decoration
	ownerdraw CG_CTF_POWERUP
	//ownerdraw CG_PLAYER_ITEM
	}
}
// player has flag
menuDef {
    	name "playerHasFlag"
    	fullScreen MENU_FALSE
    	visible MENU_TRUE
    	rect 230 435 385 32
    	
	/*itemDef {
	name "playerRect"
	rect 123 7 40 36
	style 3
	background "ui/assets/hud/flag"
	visible 1
	ownerdrawflag CG_SHOW_IF_PLAYER_HAS_FLAG            
	}*/

	itemDef {
      	name "flag"
        rect 118 6 34 34
	visible 1
	decoration
	style 2
	ownerdraw CG_PLAYER_HASFLAG 
	}

	itemDef {
      	name "skulls"
        rect 1 1 34 34
	visible 1
	decoration
	textaligny 12
	textalignx 0
	textscale 0.333
	textstyle 3
	ownerdraw CG_HARVESTER_SKULLS
	//ownerdraw CG_PLAYER_ITEM
	}
}
// graphical obits	

menuDef {
	name "obit area"
	fullScreen MENU_FALSE
	visible MENU_TRUE
	rect 3 16 65 12

    itemdef {
	    name hudObit
	    ownerdraw CG_PLAYER_OBIT
   	    rect 0 0 65 12
   	    visible 1
	    decoration
	    textscale .3
	}

}

menuDef {
	name "Borders_1"
	rect -2 16 0 0
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
	ownerdrawflag CG_SHOW_ANYNONTEAMGAME
itemDef
	{
	name "Border1"
	visible 1
	rect 608 416 32 20
	border WINDOW_BORDER_FULL
	bordersize 2
	bordercolor 0.8 0.8 0.3 1
	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
	}
itemDef
	{
	name "Border2"
	visible 1
	rect 608 436 32 20
	border WINDOW_BORDER_FULL
	bordersize 2
	bordercolor 0.8 0.8 0.3 1
	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
	}    
}
menuDef {
	name "Borders_2"
	rect -2 16 0 0
    	fullScreen MENU_FALSE
    	visible MENU_TRUE	
	ownerdrawflag CG_SHOW_ANYTEAMGAME

itemDef
	{
	name "Border3"
	visible 1
	rect 608 416 32 20
	border WINDOW_BORDER_FULL
	bordersize 2
	bordercolor 0.8 0.8 0.3 1
	ownerdrawflag CG_SHOW_IF_PLYR_IS_FIRST_PLACE
	}

itemDef
	{
	name "Border4"
	visible 1
	rect 608 436 32 20
	border WINDOW_BORDER_FULL
	bordersize 2
	bordercolor 0.8 0.8 0.3 1
	ownerdrawflag CG_SHOW_IF_PLYR_IS_NOT_FIRST_PLACE
	}    
}

// chat area	

menuDef {
	name "chat area"
	fullScreen MENU_FALSE
	visible MENU_TRUE
	rect 0 0 32 256

	//chatbgLeft
	itemDef {
		name "chatBgLeft"
		rect 3 345 16 64 
		visible 1
		ownerdrawflag CG_SHOW_IF_CHAT_VISIBLE
		decoration
		backcolor 0 0 0 0.5
		style 1
		background "ui/assets/hud/chatl.tga"
	}
	//chatbgMid
	itemDef {
		name "chatBgLeft"
		rect 19 345 561 64 
		visible 1
		ownerdrawflag CG_SHOW_IF_CHAT_VISIBLE
		decoration
		backcolor 0 0 0 0.5
		style 1
		background "ui/assets/hud/chatm.tga"
	}
	//chatbgRight
	itemDef {
		name "chatBgLeft"
		rect 580 345 16 64 
		visible 1
		ownerdrawflag CG_SHOW_IF_CHAT_VISIBLE
		decoration
		backcolor 0 0 0 0.5
		style 1
		background "ui/assets/hud/chatr.tga"
	}
	itemdef {
		name chatWindow
		ownerdraw CG_AREA_NEW_CHAT
		rect 5 287 634 120
		visible 1
		decoration
	}
    }
}
loadMenu { "ui/cross.menu" }

