TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ DefaultToMusicBox() [1/2]

void Terraria.Item.DefaultToMusicBox ( int style)
inlinepackage

Definition at line 48782 of file Item.cs.

48783 {
48784 useStyle = 1;
48785 useTurn = true;
48786 useAnimation = 15;
48787 useTime = 10;
48788 autoReuse = true;
48789 consumable = true;
48790 createTile = 139;
48791 placeStyle = style;
48792 width = 24;
48793 height = 24;
48794 rare = 4;
48795 value = 100000;
48796 accessory = true;
48797 hasVanityEffects = true;
48798 }
int width
The width of this Entity's hitbox, in pixels.
Definition Entity.cs:46
int height
The height of this Entity's hitbox, in pixels.
Definition Entity.cs:51
bool useTurn
Whether the player can turn around while the using animation of this item is happening....
Definition Item.cs:500
int useAnimation
The time span of the using animation for the item in ticks. This is independent of the time it takes ...
Definition Item.cs:384
int value
The number of copper coins this item is worth (aka, cost to buy from a merchant). Setting it to 10462...
Definition Item.cs:655
int rare
Indicates the rarity of an item. Assign to a T:Terraria.ID.ItemRarityID value. Vanilla values range f...
Definition Item.cs:587
bool hasVanityEffects
If true, this item has vanity effects even though it doesn't use equipment slots. Unused in vanilla...
Definition Item.cs:769
int createTile
The ID of the tile this item places on use. Either a T:Terraria.ID.TileID entry or M:Terraria....
Definition Item.cs:435
bool consumable
Whether the item is consumed after use. If consumed, the item stack will decrease by 1....
Definition Item.cs:488
int useStyle
Assign to an T:Terraria.ID.ItemUseStyleID value to give this item a specific animation while in use....
Definition Item.cs:366
bool accessory
Whether the item is an accessory. Defaults to false.
Definition Item.cs:378
int placeStyle
The style of the tile being placed. Used for tiles that have a different look depending on the item u...
Definition Item.cs:448
int useTime
The time span of using the item in ticks. This is independent of the time it takes for the item anima...
Definition Item.cs:391
bool autoReuse
Whether the item is in continuous use while the mouse button is held down. Defaults to false.
Definition Item.cs:494

References Terraria.Item.accessory, Terraria.Item.autoReuse, Terraria.Item.consumable, Terraria.Item.createTile, Terraria.Item.hasVanityEffects, Terraria.Entity.height, Terraria.Item.placeStyle, Terraria.Item.rare, Terraria.Item.useAnimation, Terraria.Item.useStyle, Terraria.Item.useTime, Terraria.Item.useTurn, Terraria.Item.value, and Terraria.Entity.width.