Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames

TribesGUI.ActionInventoryFlashButton


00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
class ActionInventoryFlashButton extends ActionInventoryBase;

var() actionnoresolve class<Weapon> WeaponClass;
var() actionnoresolve class<CombatRole> CombatRoleClass;
var() float duration;

// execute
latent function Variable execute()
{
	local TribesInventorySelectionMenu InventoryMenu;

	Super.execute();

	InventoryMenu = GetInventoryMenu();

	if(InventoryMenu != None)
	{
		if(CombatRoleClass != None)
			InventoryMenu.FlashArmor(CombatRoleClass, duration);
		else if(WeaponClass != None)
			InventoryMenu.FlashWeapon(WeaponClass, duration);
	}
	else
		SLog("No active inventory station menu found!");

	return None;
}

// editorDisplayString
function editorDisplayString(out string s)
{
	if(CombatRoleClass != None)
		s = "Flash the button for " $CombatRoleClass $" in the inventory station";
	else
		s = "Flash the button for " $WeaponClass $" in the inventory station";
}

defaultproperties
{
	returnType			= None
	actionDisplayName	= "Flash Inventory station button"
	actionHelp			= "Flashes a button for a class in the active Inventory station"
	category			= "UI"
}

Overview Package Class Source Class tree Glossary
previous class      next class frames      no frames
Class file time: st 16.4.2014 10:20:46.000 - Creation time: st 23.5.2018 00:10:40.352 - Created with UnCodeX