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

◆ ApplyMusicBox()

void Terraria.Player.ApplyMusicBox ( Item currentItem)
inlineprivate

Definition at line 13680 of file Player.cs.

13681 {
13682 if (currentItem.type >= 562 && currentItem.type <= 574)
13683 {
13684 Main.musicBox2 = currentItem.type - 562;
13685 }
13686 if (currentItem.type >= 1596 && currentItem.type <= 1609)
13687 {
13688 Main.musicBox2 = currentItem.type - 1596 + 13;
13689 }
13690 if (currentItem.type == 1610)
13691 {
13692 Main.musicBox2 = 27;
13693 }
13694 if (currentItem.type == 1963)
13695 {
13696 Main.musicBox2 = 28;
13697 }
13698 if (currentItem.type == 1964)
13699 {
13700 Main.musicBox2 = 29;
13701 }
13702 if (currentItem.type == 1965)
13703 {
13704 Main.musicBox2 = 30;
13705 }
13706 if (currentItem.type == 2742)
13707 {
13708 Main.musicBox2 = 31;
13709 }
13710 if (currentItem.type == 3044)
13711 {
13712 Main.musicBox2 = 32;
13713 }
13714 if (currentItem.type == 3235)
13715 {
13716 Main.musicBox2 = 33;
13717 }
13718 if (currentItem.type == 3236)
13719 {
13720 Main.musicBox2 = 34;
13721 }
13722 if (currentItem.type == 3237)
13723 {
13724 Main.musicBox2 = 35;
13725 }
13726 if (currentItem.type == 3370)
13727 {
13728 Main.musicBox2 = 36;
13729 }
13730 if (currentItem.type == 3371)
13731 {
13732 Main.musicBox2 = 37;
13733 }
13734 if (currentItem.type == 3796)
13735 {
13736 Main.musicBox2 = 38;
13737 }
13738 if (currentItem.type == 3869)
13739 {
13740 Main.musicBox2 = 39;
13741 }
13742 if (currentItem.type == 4082)
13743 {
13744 Main.musicBox2 = 40;
13745 }
13746 if (currentItem.type == 4078)
13747 {
13748 Main.musicBox2 = 41;
13749 }
13750 if (currentItem.type == 4079)
13751 {
13752 Main.musicBox2 = 42;
13753 }
13754 if (currentItem.type == 4077)
13755 {
13756 Main.musicBox2 = 43;
13757 }
13758 if (currentItem.type == 4080)
13759 {
13760 Main.musicBox2 = 44;
13761 }
13762 if (currentItem.type == 4081)
13763 {
13764 Main.musicBox2 = 45;
13765 }
13766 if (currentItem.type == 4237)
13767 {
13768 Main.musicBox2 = 46;
13769 }
13770 if (currentItem.type == 4356)
13771 {
13772 Main.musicBox2 = 47;
13773 }
13774 if (currentItem.type == 4357)
13775 {
13776 Main.musicBox2 = 48;
13777 }
13778 if (currentItem.type == 4358)
13779 {
13780 Main.musicBox2 = 49;
13781 }
13782 if (currentItem.type == 4421)
13783 {
13784 Main.musicBox2 = 50;
13785 }
13786 if (currentItem.type == 4606)
13787 {
13788 Main.musicBox2 = 51;
13789 }
13790 if (currentItem.type == 4979)
13791 {
13792 Main.musicBox2 = 52;
13793 }
13794 if (currentItem.type == 4985)
13795 {
13796 Main.musicBox2 = 53;
13797 }
13798 if (currentItem.type == 4990)
13799 {
13800 Main.musicBox2 = 54;
13801 }
13802 if (currentItem.type == 4991)
13803 {
13804 Main.musicBox2 = 55;
13805 }
13806 if (currentItem.type == 4992)
13807 {
13808 Main.musicBox2 = 56;
13809 }
13810 if (currentItem.type == 5006)
13811 {
13812 Main.musicBox2 = 57;
13813 }
13814 if (currentItem.type == 5014)
13815 {
13816 Main.musicBox2 = 58;
13817 }
13818 if (currentItem.type == 5015)
13819 {
13820 Main.musicBox2 = 59;
13821 }
13822 if (currentItem.type == 5016)
13823 {
13824 Main.musicBox2 = 60;
13825 }
13826 if (currentItem.type == 5017)
13827 {
13828 Main.musicBox2 = 61;
13829 }
13830 if (currentItem.type == 5018)
13831 {
13832 Main.musicBox2 = 62;
13833 }
13834 if (currentItem.type == 5019)
13835 {
13836 Main.musicBox2 = 63;
13837 }
13838 if (currentItem.type == 5020)
13839 {
13840 Main.musicBox2 = 64;
13841 }
13842 if (currentItem.type == 5021)
13843 {
13844 Main.musicBox2 = 65;
13845 }
13846 if (currentItem.type == 5022)
13847 {
13848 Main.musicBox2 = 66;
13849 }
13850 if (currentItem.type == 5023)
13851 {
13852 Main.musicBox2 = 67;
13853 }
13854 if (currentItem.type == 5024)
13855 {
13856 Main.musicBox2 = 68;
13857 }
13858 if (currentItem.type == 5025)
13859 {
13860 Main.musicBox2 = 69;
13861 }
13862 if (currentItem.type == 5026)
13863 {
13864 Main.musicBox2 = 70;
13865 }
13866 if (currentItem.type == 5027)
13867 {
13868 Main.musicBox2 = 71;
13869 }
13870 if (currentItem.type == 5028)
13871 {
13872 Main.musicBox2 = 72;
13873 }
13874 if (currentItem.type == 5029)
13875 {
13876 Main.musicBox2 = 73;
13877 }
13878 if (currentItem.type == 5030)
13879 {
13880 Main.musicBox2 = 74;
13881 }
13882 if (currentItem.type == 5031)
13883 {
13884 Main.musicBox2 = 75;
13885 }
13886 if (currentItem.type == 5032)
13887 {
13888 Main.musicBox2 = 76;
13889 }
13890 if (currentItem.type == 5033)
13891 {
13892 Main.musicBox2 = 77;
13893 }
13894 if (currentItem.type == 5034)
13895 {
13896 Main.musicBox2 = 78;
13897 }
13898 if (currentItem.type == 5035)
13899 {
13900 Main.musicBox2 = 79;
13901 }
13902 if (currentItem.type == 5036)
13903 {
13904 Main.musicBox2 = 80;
13905 }
13906 if (currentItem.type == 5037)
13907 {
13908 Main.musicBox2 = 81;
13909 }
13910 if (currentItem.type == 5038)
13911 {
13912 Main.musicBox2 = 82;
13913 }
13914 if (currentItem.type == 5039)
13915 {
13916 Main.musicBox2 = 83;
13917 }
13918 if (currentItem.type == 5040)
13919 {
13920 Main.musicBox2 = 84;
13921 }
13922 if (currentItem.type == 5044)
13923 {
13924 Main.musicBox2 = 85;
13925 }
13926 if (currentItem.type == 5112)
13927 {
13928 Main.musicBox2 = 86;
13929 }
13930 if (currentItem.type == 5362)
13931 {
13932 Main.musicBox2 = 87;
13933 }
13934 if (MusicLoader.itemToMusic.TryGetValue(currentItem.type, out var modMusicBox))
13935 {
13936 Main.musicBox2 = modMusicBox;
13937 }
13938 Main.musicBoxNotModifiedByVolume = Main.musicBox2;
13939 }
static readonly Dictionary< int, int > itemToMusic
Unloaded server side.

References Terraria.ModLoader.MusicLoader.itemToMusic, and Terraria.Main.musicBox2.

Referenced by Terraria.Player.ApplyEquipFunctional(), and Terraria.Player.ApplyEquipVanity().

+ Here is the caller graph for this function: