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

◆ paintColor()

static Color Terraria.WorldGen.paintColor ( int color)
inlinestatic

Definition at line 36685 of file WorldGen.cs.

36686 {
36687 //IL_0000: Unknown result type (might be due to invalid IL or missing references)
36688 //IL_0005: Unknown result type (might be due to invalid IL or missing references)
36689 //IL_02c5: Unknown result type (might be due to invalid IL or missing references)
36690 Color white = Color.White;
36691 if (color == 1 || color == 13)
36692 {
36693 ((Color)(ref white)).R = byte.MaxValue;
36694 ((Color)(ref white)).G = 0;
36695 ((Color)(ref white)).B = 0;
36696 }
36697 if (color == 2 || color == 14)
36698 {
36699 ((Color)(ref white)).R = byte.MaxValue;
36700 ((Color)(ref white)).G = 127;
36701 ((Color)(ref white)).B = 0;
36702 }
36703 if (color == 3 || color == 15)
36704 {
36705 ((Color)(ref white)).R = byte.MaxValue;
36706 ((Color)(ref white)).G = byte.MaxValue;
36707 ((Color)(ref white)).B = 0;
36708 }
36709 if (color == 4 || color == 16)
36710 {
36711 ((Color)(ref white)).R = 127;
36712 ((Color)(ref white)).G = byte.MaxValue;
36713 ((Color)(ref white)).B = 0;
36714 }
36715 if (color == 5 || color == 17)
36716 {
36717 ((Color)(ref white)).R = 0;
36718 ((Color)(ref white)).G = byte.MaxValue;
36719 ((Color)(ref white)).B = 0;
36720 }
36721 if (color == 6 || color == 18)
36722 {
36723 ((Color)(ref white)).R = 0;
36724 ((Color)(ref white)).G = byte.MaxValue;
36725 ((Color)(ref white)).B = 127;
36726 }
36727 if (color == 7 || color == 19)
36728 {
36729 ((Color)(ref white)).R = 0;
36730 ((Color)(ref white)).G = byte.MaxValue;
36731 ((Color)(ref white)).B = byte.MaxValue;
36732 }
36733 if (color == 8 || color == 20)
36734 {
36735 ((Color)(ref white)).R = 0;
36736 ((Color)(ref white)).G = 127;
36737 ((Color)(ref white)).B = byte.MaxValue;
36738 }
36739 if (color == 9 || color == 21)
36740 {
36741 ((Color)(ref white)).R = 0;
36742 ((Color)(ref white)).G = 0;
36743 ((Color)(ref white)).B = byte.MaxValue;
36744 }
36745 if (color == 10 || color == 22)
36746 {
36747 ((Color)(ref white)).R = 127;
36748 ((Color)(ref white)).G = 0;
36749 ((Color)(ref white)).B = byte.MaxValue;
36750 }
36751 if (color == 11 || color == 23)
36752 {
36753 ((Color)(ref white)).R = byte.MaxValue;
36754 ((Color)(ref white)).G = 0;
36755 ((Color)(ref white)).B = byte.MaxValue;
36756 }
36757 if (color == 12 || color == 24)
36758 {
36759 ((Color)(ref white)).R = byte.MaxValue;
36760 ((Color)(ref white)).G = 0;
36761 ((Color)(ref white)).B = 127;
36762 }
36763 if (color == 25)
36764 {
36765 ((Color)(ref white)).R = 75;
36766 ((Color)(ref white)).G = 75;
36767 ((Color)(ref white)).B = 75;
36768 }
36769 if (color == 26)
36770 {
36771 ((Color)(ref white)).R = byte.MaxValue;
36772 ((Color)(ref white)).G = byte.MaxValue;
36773 ((Color)(ref white)).B = byte.MaxValue;
36774 }
36775 if (color == 27)
36776 {
36777 ((Color)(ref white)).R = 175;
36778 ((Color)(ref white)).G = 175;
36779 ((Color)(ref white)).B = 175;
36780 }
36781 if (color == 28)
36782 {
36783 ((Color)(ref white)).R = byte.MaxValue;
36784 ((Color)(ref white)).G = 178;
36785 ((Color)(ref white)).B = 125;
36786 }
36787 if (color == 29)
36788 {
36789 ((Color)(ref white)).R = 25;
36790 ((Color)(ref white)).G = 25;
36791 ((Color)(ref white)).B = 25;
36792 }
36793 if (color == 30)
36794 {
36795 ((Color)(ref white)).R = 200;
36796 ((Color)(ref white)).G = 200;
36797 ((Color)(ref white)).B = 200;
36798 ((Color)(ref white)).A = 150;
36799 }
36800 return white;
36801 }

Referenced by Terraria.Graphics.Light.TileLightScanner.ApplyTileLight(), Terraria.GameContent.Drawing.TileDrawing.DrawTrees(), Terraria.Map.MapHelper.MapColor(), and Terraria.Main.TryApplyingPlayerStringColor().

+ Here is the caller graph for this function: