-- Constants
INVALID_THREAD_HANDLE = -1
INVALID_WEAPON_UNIQUE_ID = -1
INVALID_WEAPON_INVENTORY_SLOT = 0 -- This is 0 because we're starting from 1 for Lua
INVALID_NANO_INVENTORY_SLOT = 0 -- This is 0 because we're starting from 1 for Lua
INVALID_VDO_HANDLE = -1
TYPE_BUTTON = 0
TYPE_TOGGLE = 1
TYPE_SLIDER = 2
TYPE_ROW = 3
TYPE_REMAP = 4 --PC-only shortcut remapping
TYPE_TOGGLE_COLOR = 5 --Color
SCALE_STD_RES = 0.67
ALIGN_DEFAULT = 0
ALIGN_LEFT = 1
ALIGN_CENTER = 2
ALIGN_RIGHT = 3
LIST_BUTTON_SPACE = 3
LIST_BUTTON_SPACING = 35
LIST_BUTTON_HEIGHT = 32
LIST_HIGHLIGHT_HEIGHT = 10
LIST_BUTTON_TEXT_X = 48
LIST_TOGGLE_OFFSET = 0.75
LIST_SLIDER_OFFSET = 0.25
SCROLLBAR_WIDTH = 10
DEG_TO_RAD = 0.01745329252 -- PI/180
--setup global colors
--Pause Menu Colors
COLOR_PM_BAR = {R = 208/255, G = 74/255; B = 146/255}
--Depreciated
COLOR_HIGHLIGHT_TEXT = {R=180,G=36,B=18}
COLOR_HIGHLIGHT_BG = {R=0,G=133,B=192}
COLOR_UNHIGHLIGHT_TEXT = {R=160,G=160,B=160}
COLOR_UNHIGHLIGHT_BG = {R=40,G=40,B=40}
COLOR_DISABLED_TEXT = {R=50,G=50,B=50}
COLOR_DISABLED_BG = {R=20,G=20,B=20}
COLOR_RED = {R=182, G=36, B=18}
COLOR_RED_MEDIUM = {R=102, G=20, B=10}
COLOR_RED_DARK = {R=48, G=9, B=5}
COLOR_SAINTS_PURPLE = {R=148/255, G=0/255, B=197/255}
COLOR_STORE_WEAPON_PRIMARY = {R=184/255, G=73/255, B=48/255}
COLOR_STORE_WEAPON_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_WEAPON_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_STORE_VEHICLE_PRIMARY = {R=204/255, G=204/255, B=204/255}
COLOR_STORE_VEHICLE_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_VEHICLE_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_PLAYER_CREATION_PRIMARY = {R=177/255, G=118/255, B=10/255}
COLOR_PLAYER_CREATION_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_PLAYER_CREATION_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_STORE_CHARACTER_PRIMARY = {R=72/255, G=165/255, B=206/255}
COLOR_STORE_CHARACTER_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_CHARACTER_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_CELL_MENU_HIGHLIGHT_TEXT = {R=220/255,G=220/255,B=220/255}
COLOR_CELL_MENU_HIGHLIGHT_BTN = {R=146/255, G=143/255, B=225/255}
--COLOR_CELL_MENU_HIGHLIGHT_BTN_SHADOW = {R=31/255, G=32/255, B=71/255}
COLOR_CELL_MENU_UNHIGHLIGHT_TEXT = {R=120/255,G=120/255,B=120/255}
COLOR_CELL_MENU_UNHIGHLIGHT_BTN = {R=54/255, G=52/255, B=123/255}
COLOR_CELL_MENU_UNHIGHLIGHT_BTN_SHADOW = {R=31/255, G=32/255, B=71/255}
COLOR_CHEATS_PRIMARY = {R=148/255, G=0/255, B=197/255}
COLOR_CHEATS_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_REWARDS_PRIMARY = {R=148/255, G=0/255, B=197/255}
COLOR_STORE_REWARDS_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_REWARDS_TERTIARY = {R=90/255, G=90/255, B=90/255}
COLOR_STORE_REWARDS_UNHIGHLIGHTED = {R=120/255, G=120/255, B=120/255}
COLOR_STORE_CLOTHING_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_CLOTHING_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_STORE_LETS_PRETEND_PRIMARY = {R=64/255, G=184/255, B=33/255}
COLOR_STORE_LETS_PRETEND_SECONDARY = {R=170/255, G=170/255, B=170/255}
COLOR_STORE_LETS_PRETEND_TERTIARY = {R=97/255, G=100/255, B=102/255}
COLOR_STORE_LETS_PRETEND_PINK = {R=208/255, G=74/255, B=146/255}
COLOR_STORE_LACE_PRIMARY = {R=208/255, G=75/255, B=146/255}
COLOR_STORE_NOBODY_PRIMARY = {R=22/255, G=136/255, B=198/255}
COLOR_STORE_PLANET_PRIMARY = {R=148/255, G=0/255, B=197/255}
COLOR_STORE_IMPRESSIONS_PRIMARY = {R=153/255, G=128/255, B=77/255}
COLOR_RESPECT_METER = {R=148/255, g=0/255, B=197/255}
COLOR_RESPECT_METER_HIGHLIGHT = {R=165/255, g=0/255, B=219/255}
COLOR_TARGET_KILL = {R=204/255, G=34/255, B=0}
COLOR_TARGET_DEFEND = {R=101/255, G=178/255, B=76/255}
COLOR_TARGET_USE = {R=246/255, G=187/255, B=79/255}
COLOR_TARGET_REVIVE = {R=104/255, G=100/255, B=238/255}
COLOR_TARGET_LOCATION = {R=25/255, G=157/255, B=229/255}
COLOR_TARGET_COOP = {R=148/255, g=0/255, B=197/255}
COLOR_TARGET_HITMAN = {R=255/255, G=255/255, B=255/255}
COLOR_TARGET_CHOPSHOP = {R=255/255, G=255/255, B=255/255}
COLOR_TARGET_SYNDICATE = {R=208/255, G=74/255, B=146/255}
COLOR_TARGET_SAINTS = {R=148/255, G=0/255, B=197/255}
COLOR_TARGET_GRENADE = {R=220/255, G=220/255, B=220/255}
COLOR_CMP_FAIL = {R=156/255, G=35/255, B=32/255}
TWEEN_STATE_IDLE = 0
TWEEN_STATE_RUNNING = 1
TWEEN_STATE_PAUSED = 2
TWEEN_STATE_DISABLED = 3
TWEEN_STATE_FINISHED = 4
HUD_DISPOSITION_FRIENDLY = 0
HUD_DISPOSITION_ENEMY = 1
HUD_DISPOSITION_NEUTRAL = 2
HUMAN_TEAM_NONE = -1
HUMAN_TEAM_GUERILLA = 0
HUMAN_TEAM_EDF = 1
HUMAN_TEAM_CIVILIAN = 2
HUMAN_TEAM_MP_NEUTRAL = 2
HUMAN_TEAM_MARAUDER = 3
HUMAN_TEAM_MP_SPECTATOR = 3
COLOR_CONTROL = {R=0.58,G=0.05,B=0}
COLOR_MORALE = {R=0.943,G=0.78,B=0.20}
COLOR_PING_RED = {R=171/255, G=47/255, B=15/255}
COLOR_PING_YELLOW = {R=218/255, G=199/255, B=17/255}
COLOR_PING_GREEN = {R=113/255, G=175/255, B=21/255}
COLOR_PING_GREY = {R=190/255, G=190/255, B=190/255}
INVENTORY_DPAD_THRESHOLD = .25 --The dpad is analog on PS3 so we can set the threshold with this.
-- Sound IDS. Use these with "play_ui_sound" gameside Lua function to play any sounds.
-- If you want to add to these, you need to update the UIS_ enums in gameaudio.cpp, as well as the gameside
-- functions that map the UIS_ enum values to sound IDs and the code that loads these IDs, as well as possibly
-- the table file that the event names are loaded from (game_audio.xtbl) and the global cue IDs list.
SOUND_SLIDER_ADD = ""
SOUND_SLIDER_SUBTRACT = ""
SOUND_INPUT_CONFIRM = "INT_SELECT"
SOUND_INPUT_A = SOUND_INPUT_CONFIRM -- Confirm
SOUND_INPUT_CANCEL = "INT_BACK"
SOUND_INPUT_B = SOUND_INPUT_CANCEL -- Cancel/Back
SOUND_INPUT_MISC = ""
SOUND_INPUT_X = SOUND_INPUT_MISC
SOUND_INPUT_OTHER = ""
SOUND_INPUT_Y = SOUND_INPUT_OTHER
SOUND_SCROLL_UP = "INT_TOGGLE_UD" -- Dpad stuff
SOUND_SCROLL_DOWN = "INT_TOGGLE_UD" -- Dpad stuff
SOUND_SCROLL_LEFT = "INT_TOGGLE_UD" -- Dpad stuff
SOUND_SCROLL_RIGHT = "INT_TOGGLE_UD" -- Dpad stuff
SOUND_BUMPER_RIGHT = "INT_TRIGGER" -- Use these
SOUND_BUMPER_LEFT = "INT_TRIGGER" -- Use these
SOUND_TRIGGER_RIGHT = "INT_TRIGGER" -- Use these
SOUND_TRIGGER_LEFT = "INT_TRIGGER" -- Use these
SOUND_INPUT_INVALID = "INT_ERROR" -- Option does not exist
SOUND_LEFT_STICK_PRESS = ""
SOUND_RIGHT_STICK_PRESS = ""
SOUND_DPAD_UP = "INT_TOGGLE_UD"
SOUND_DPAD_DOWN = "INT_TOGGLE_UD"
SOUND_DPAD_RIGHT = "INT_TOGGLE_UD"
SOUND_DPAD_LEFT = "INT_TOGGLE_UD"
SOUND_AMBIENT_ADJUST = ""
SOUND_MUSIC_VOLUME_ADJUST = ""
SOUND_SFX_VOLUME_ADJUST = ""
SOUND_VOICE_VOLUME_ADJUST = ""
SOUND_OVERALL_VOLUME_ADJUST = ""
SOUND_WEAPON_RADIAL_OPEN = 26 -- Open weapons
SOUND_WEAPON_RADIAL_CLOSE = 27 -- Close weapons
SOUND_WEAPON_RADIAL_HIGHLIGHT_NEW_WEAPON = 28 -- Move the cursor on the weapon
SOUND_WEAPON_RADIAL_SELECT_WEAPON = 29 -- Pick weapon on radial
SOUND_NANOFORGE_RADIAL_OPEN = 30 -- Open nano
SOUND_NANOFORGE_RADIAL_CLOSE = 31 -- Close nano
SOUND_NANOFORGE_RADIAL_HIGHLIGHT_NEW_ABILITY = 32 -- Move cursor on nano
SOUND_WEAPON_UPGRADE_SCROLL_UP = 33
SOUND_WEAPON_UPGRADE_SCROLL_DOWN = 34
SOUND_WEAPON_UPGRADE_SELECT_UPGRADE = 35
SOUND_WEAPON_UPGRADE_HIGHLIGHT_NEW_UPGRADE = 36
SOUND_WEAPON_UPGRADE_PURCHASE_STANDARD_UPGRADE = 37
SOUND_WEAPON_UPGRADE_PURCHASE_SUPER_UPGRADE = 38
SOUND_WEAPON_UPGRADE_SCREEN_OPEN = 39
SOUND_WEAPON_UPGRADE_SCREEN_CLOSE = 40
SOUND_PAUSE_MENU_OPEN = 43
-- next unused number: 44
-- Global Return Screen Values
Global_last_tier = 1
Global_last_option = 1
Global_last_pause_tier = 1
Global_last_pause_option = 1
Global_last_lobby_tier = 1
Global_last_lobby_option = 1
Global_matchmaking_level_id = 0
Global_matchmaking_difficulty_id = -1
function multi_player_lobby_reset()
Global_last_lobby_tier = 1
Global_last_lobby_option = 1
Global_matchmaking_level_id = 0
Global_matchmaking_difficulty_id = -1
end
--[[
Removing all references to this (JMH 6/17/2010)
function vint_set_child_tween_target_handle()
--
end
]]
--[[
Removing all references to this (JMH 6/17/2010)
function vint_set_child_tween_state()
--
end
]]
function play_ui_sound()
end
local UI_test_sound_h = nil
-- sound == nil means to stop
function ui_test_rtpc(sound, rtpc, value)
if UI_test_sound_h then
game_audio_stop(UI_test_sound_h)
UI_test_sound_h = nil
end
if sound then
UI_test_sound_h = game_UI_audio_play(sound)
game_audio_set_rtpc(UI_test_sound_h, rtpc, value)
end
end