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

◆ UpdateItem_VisualEffects()

void Terraria.Item.UpdateItem_VisualEffects ( )
inlineprivate

Definition at line 50947 of file Item.cs.

50948 {
50949 //IL_06bb: Unknown result type (might be due to invalid IL or missing references)
50950 //IL_06cf: Unknown result type (might be due to invalid IL or missing references)
50951 //IL_06d9: Unknown result type (might be due to invalid IL or missing references)
50952 //IL_06f2: Unknown result type (might be due to invalid IL or missing references)
50953 //IL_0706: Unknown result type (might be due to invalid IL or missing references)
50954 //IL_0710: Unknown result type (might be due to invalid IL or missing references)
50955 //IL_0729: Unknown result type (might be due to invalid IL or missing references)
50956 //IL_073d: Unknown result type (might be due to invalid IL or missing references)
50957 //IL_0747: Unknown result type (might be due to invalid IL or missing references)
50958 //IL_0760: Unknown result type (might be due to invalid IL or missing references)
50959 //IL_0774: Unknown result type (might be due to invalid IL or missing references)
50960 //IL_077e: Unknown result type (might be due to invalid IL or missing references)
50961 //IL_0820: Unknown result type (might be due to invalid IL or missing references)
50962 //IL_07a7: Unknown result type (might be due to invalid IL or missing references)
50963 //IL_07ca: Unknown result type (might be due to invalid IL or missing references)
50964 //IL_07e4: Unknown result type (might be due to invalid IL or missing references)
50965 //IL_07ee: Unknown result type (might be due to invalid IL or missing references)
50966 //IL_07f3: Unknown result type (might be due to invalid IL or missing references)
50967 //IL_0e1b: Unknown result type (might be due to invalid IL or missing references)
50968 //IL_1747: Unknown result type (might be due to invalid IL or missing references)
50969 //IL_1832: Unknown result type (might be due to invalid IL or missing references)
50970 //IL_1841: Unknown result type (might be due to invalid IL or missing references)
50971 //IL_1872: Unknown result type (might be due to invalid IL or missing references)
50972 //IL_1881: Unknown result type (might be due to invalid IL or missing references)
50973 //IL_1d1b: Unknown result type (might be due to invalid IL or missing references)
50974 //IL_1d32: Unknown result type (might be due to invalid IL or missing references)
50975 //IL_1d37: Unknown result type (might be due to invalid IL or missing references)
50976 //IL_1d55: Unknown result type (might be due to invalid IL or missing references)
50977 //IL_1d70: Unknown result type (might be due to invalid IL or missing references)
50978 //IL_1d75: Unknown result type (might be due to invalid IL or missing references)
50979 //IL_1da0: Unknown result type (might be due to invalid IL or missing references)
50980 //IL_1dae: Unknown result type (might be due to invalid IL or missing references)
50981 //IL_1db4: Unknown result type (might be due to invalid IL or missing references)
50982 //IL_1e4e: Unknown result type (might be due to invalid IL or missing references)
50983 //IL_1e65: Unknown result type (might be due to invalid IL or missing references)
50984 //IL_1e6a: Unknown result type (might be due to invalid IL or missing references)
50985 //IL_1e8e: Unknown result type (might be due to invalid IL or missing references)
50986 //IL_1ea9: Unknown result type (might be due to invalid IL or missing references)
50987 //IL_1eae: Unknown result type (might be due to invalid IL or missing references)
50988 //IL_1ed9: Unknown result type (might be due to invalid IL or missing references)
50989 //IL_1ee7: Unknown result type (might be due to invalid IL or missing references)
50990 //IL_1eed: Unknown result type (might be due to invalid IL or missing references)
50991 if (type == 5043)
50992 {
50993 float num = (float)Main.rand.Next(90, 111) * 0.01f;
50994 num *= (Main.essScale + 0.5f) / 2f;
50995 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.25f * num, 0.25f * num, 0.25f * num);
50996 }
50997 else if (type == 3191)
50998 {
50999 float num9 = (float)Main.rand.Next(90, 111) * 0.01f;
51000 num9 *= (Main.essScale + 0.5f) / 2f;
51001 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.3f * num9, 0.1f * num9, 0.25f * num9);
51002 }
51003 else if (type == 520 || type == 3454)
51004 {
51005 float num10 = (float)Main.rand.Next(90, 111) * 0.01f;
51006 num10 *= Main.essScale;
51007 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f * num10, 0.1f * num10, 0.25f * num10);
51008 }
51009 else if (type == 521 || type == 3455)
51010 {
51011 float num11 = (float)Main.rand.Next(90, 111) * 0.01f;
51012 num11 *= Main.essScale;
51013 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.25f * num11, 0.1f * num11, 0.5f * num11);
51014 }
51015 else if (type == 547 || type == 3453)
51016 {
51017 float num12 = (float)Main.rand.Next(90, 111) * 0.01f;
51018 num12 *= Main.essScale;
51019 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f * num12, 0.3f * num12, 0.05f * num12);
51020 }
51021 else if (type == 548)
51022 {
51023 float num13 = (float)Main.rand.Next(90, 111) * 0.01f;
51024 num13 *= Main.essScale;
51025 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.1f * num13, 0.1f * num13, 0.6f * num13);
51026 }
51027 else if (type == 575)
51028 {
51029 float num14 = (float)Main.rand.Next(90, 111) * 0.01f;
51030 num14 *= Main.essScale;
51031 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.1f * num14, 0.3f * num14, 0.5f * num14);
51032 }
51033 else if (type == 549)
51034 {
51035 float num15 = (float)Main.rand.Next(90, 111) * 0.01f;
51036 num15 *= Main.essScale;
51037 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.1f * num15, 0.5f * num15, 0.2f * num15);
51038 }
51039 else if (type == 58 || type == 1734 || type == 1867)
51040 {
51041 float num16 = (float)Main.rand.Next(90, 111) * 0.01f;
51042 num16 *= Main.essScale * 0.5f;
51043 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f * num16, 0.1f * num16, 0.1f * num16);
51044 }
51045 else if (type == 184 || type == 1735 || type == 1868 || type == 4143)
51046 {
51047 float num2 = (float)Main.rand.Next(90, 111) * 0.01f;
51048 num2 *= Main.essScale * 0.5f;
51049 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.1f * num2, 0.1f * num2, 0.5f * num2);
51050 }
51051 else if (type == 522)
51052 {
51053 float num3 = (float)Main.rand.Next(90, 111) * 0.01f;
51054 num3 *= Main.essScale * 0.2f;
51055 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f * num3, 1f * num3, 0.1f * num3);
51056 }
51057 else if (type == 1332)
51058 {
51059 float num4 = (float)Main.rand.Next(90, 111) * 0.01f;
51060 num4 *= Main.essScale * 0.2f;
51061 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f * num4, 1f * num4, 0.1f * num4);
51062 }
51063 else if (type == 3456)
51064 {
51065 Lighting.AddLight(base.Center, new Vector3(0.2f, 0.4f, 0.5f) * Main.essScale);
51066 }
51067 else if (type == 3457)
51068 {
51069 Lighting.AddLight(base.Center, new Vector3(0.4f, 0.2f, 0.5f) * Main.essScale);
51070 }
51071 else if (type == 3458)
51072 {
51073 Lighting.AddLight(base.Center, new Vector3(0.5f, 0.4f, 0.2f) * Main.essScale);
51074 }
51075 else if (type == 3459)
51076 {
51077 Lighting.AddLight(base.Center, new Vector3(0.2f, 0.2f, 0.5f) * Main.essScale);
51078 }
51079 else if (type == 501)
51080 {
51081 if (Main.rand.Next(6) == 0)
51082 {
51083 int num5 = Dust.NewDust(position, width, height, 55, 0f, 0f, 200, color);
51084 Dust obj = Main.dust[num5];
51085 obj.velocity *= 0.3f;
51086 Main.dust[num5].scale *= 0.5f;
51087 }
51088 }
51089 else if (type == 3822)
51090 {
51091 Lighting.AddLight(base.Center, 0.1f, 0.3f, 0.1f);
51092 }
51093 else if (type == 1970)
51094 {
51095 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0f, 0.75f);
51096 }
51097 else if (type == 1972)
51098 {
51099 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0f, 0f, 0.75f);
51100 }
51101 else if (type == 1971)
51102 {
51103 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0.75f, 0f);
51104 }
51105 else if (type == 1973)
51106 {
51107 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0f, 0.75f, 0f);
51108 }
51109 else if (type == 1974)
51110 {
51111 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0f, 0f);
51112 }
51113 else if (type == 1975)
51114 {
51115 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0.75f, 0.75f);
51116 }
51117 else if (type == 1976)
51118 {
51119 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0.375f, 0f);
51120 }
51121 else if (type == 2679)
51122 {
51123 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.6f, 0f, 0.6f);
51124 }
51125 else if (type == 2687)
51126 {
51127 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0f, 0f, 0.6f);
51128 }
51129 else if (type == 2689)
51130 {
51131 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.6f, 0.6f, 0f);
51132 }
51133 else if (type == 2683)
51134 {
51135 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0f, 0.6f, 0f);
51136 }
51137 else if (type == 2685)
51138 {
51139 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.6f, 0f, 0f);
51140 }
51141 else if (type == 2681)
51142 {
51143 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.6f, 0.6f, 0.6f);
51144 }
51145 else if (type == 2677)
51146 {
51147 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.6f, 0.375f, 0f);
51148 }
51149 else if (type == 105)
51150 {
51151 if (!wet)
51152 {
51153 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f, 0.95f, 0.8f);
51154 }
51155 }
51156 else if (type == 2701)
51157 {
51158 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.7f, 0.65f, 0.55f);
51159 }
51160 else if (createTile == 4)
51161 {
51162 int torchID = placeStyle;
51164 {
51165 Lighting.AddLight(base.Center, torchID);
51166 }
51167 }
51168 else if (type == 3114)
51169 {
51170 if (!wet)
51171 {
51172 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f, 0f, 1f);
51173 }
51174 }
51175 else if (type == 1245)
51176 {
51177 if (!wet)
51178 {
51179 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f, 0.5f, 0f);
51180 }
51181 }
51182 else if (type == 433)
51183 {
51184 if (!wet)
51185 {
51186 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f * Main.demonTorch + 1f * (1f - Main.demonTorch), 0.3f, 1f * Main.demonTorch + 0.5f * (1f - Main.demonTorch));
51187 }
51188 }
51189 else if (type == 523)
51190 {
51191 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.85f, 1.2f, 0.7f);
51192 }
51193 else if (type == 974)
51194 {
51195 if (!wet)
51196 {
51197 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.75f, 0.85f, 1.4f);
51198 }
51199 }
51200 else if (type == 1333)
51201 {
51202 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1.25f, 1.25f, 0.7f);
51203 }
51204 else if (type == 4383)
51205 {
51206 if (!wet)
51207 {
51208 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1.4f, 0.85f, 0.55f);
51209 }
51210 }
51211 else if (type == 5293)
51212 {
51213 if (!wet)
51214 {
51215 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.25f, 0.65f, 1f);
51216 }
51217 }
51218 else if (type == 5353)
51219 {
51220 if (!wet)
51221 {
51222 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.81f, 0.72f, 1f);
51223 }
51224 }
51225 else if (type == 4384)
51226 {
51227 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.25f, 1.3f, 0.8f);
51228 }
51229 else if (type == 3045)
51230 {
51231 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), (float)Main.DiscoR / 255f, (float)Main.DiscoG / 255f, (float)Main.DiscoB / 255f);
51232 }
51233 else if (type == 3004)
51234 {
51235 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.95f, 0.65f, 1.3f);
51236 }
51237 else if (type == 2274)
51238 {
51239 float r = 0.75f;
51240 float g = 1.3499999f;
51241 float b = 1.5f;
51242 if (!wet)
51243 {
51244 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), r, g, b);
51245 }
51246 }
51247 else if (type >= 427 && type <= 432)
51248 {
51249 if (!wet)
51250 {
51251 float r2 = 0f;
51252 float g2 = 0f;
51253 float b2 = 0f;
51254 int num17 = type - 426;
51255 if (num17 == 1)
51256 {
51257 r2 = 0.1f;
51258 g2 = 0.2f;
51259 b2 = 1.1f;
51260 }
51261 if (num17 == 2)
51262 {
51263 r2 = 1f;
51264 g2 = 0.1f;
51265 b2 = 0.1f;
51266 }
51267 if (num17 == 3)
51268 {
51269 r2 = 0f;
51270 g2 = 1f;
51271 b2 = 0.1f;
51272 }
51273 if (num17 == 4)
51274 {
51275 r2 = 0.9f;
51276 g2 = 0f;
51277 b2 = 0.9f;
51278 }
51279 if (num17 == 5)
51280 {
51281 r2 = 1.3f;
51282 g2 = 1.3f;
51283 b2 = 1.3f;
51284 }
51285 if (num17 == 6)
51286 {
51287 r2 = 0.9f;
51288 g2 = 0.9f;
51289 b2 = 0f;
51290 }
51291 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), r2, g2, b2);
51292 }
51293 }
51294 else if (type == 2777 || type == 2778 || type == 2779 || type == 2780 || type == 2781 || type == 2760 || type == 2761 || type == 2762 || type == 3524)
51295 {
51296 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.4f, 0.16f, 0.36f);
51297 }
51298 else if (type == 2772 || type == 2773 || type == 2774 || type == 2775 || type == 2776 || type == 2757 || type == 2758 || type == 2759 || type == 3523)
51299 {
51300 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0f, 0.36f, 0.4f);
51301 }
51302 else if (type == 2782 || type == 2783 || type == 2784 || type == 2785 || type == 2786 || type == 2763 || type == 2764 || type == 2765 || type == 3522)
51303 {
51304 Lighting.AddLight((int)((position.X + (float)(width / 2)) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.5f, 0.25f, 0.05f);
51305 }
51306 else if (type == 3462 || type == 3463 || type == 3464 || type == 3465 || type == 3466 || type == 3381 || type == 3382 || type == 3383 || type == 3525)
51307 {
51308 Lighting.AddLight(base.Center, 0.3f, 0.3f, 0.2f);
51309 }
51310 else if (type == 41)
51311 {
51312 if (!wet)
51313 {
51314 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f, 0.75f, 0.55f);
51315 }
51316 }
51317 else if (type == 988)
51318 {
51319 if (!wet)
51320 {
51321 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.35f, 0.65f, 1f);
51322 }
51323 }
51324 else if (type == 1326)
51325 {
51326 Lighting.AddLight((int)base.Center.X / 16, (int)base.Center.Y / 16, 1f, 0.1f, 0.8f);
51327 }
51328 else if (type == 5335)
51329 {
51330 Lighting.AddLight((int)base.Center.X / 16, (int)base.Center.Y / 16, 0.85f, 0.1f, 0.8f);
51331 }
51332 else if (type >= 5140 && type <= 5146)
51333 {
51334 float num6 = 1f;
51335 float num7 = 1f;
51336 float num8 = 1f;
51337 switch (type)
51338 {
51339 case 5140:
51340 num6 *= 0.9f;
51341 num7 *= 0.8f;
51342 num8 *= 0.1f;
51343 break;
51344 case 5141:
51345 num6 *= 0.25f;
51346 num7 *= 0.1f;
51347 num8 *= 0f;
51348 break;
51349 case 5142:
51350 num6 *= 0f;
51351 num7 *= 0.25f;
51352 num8 *= 0f;
51353 break;
51354 case 5143:
51355 num6 *= 0f;
51356 num7 *= 0.16f;
51357 num8 *= 0.34f;
51358 break;
51359 case 5144:
51360 num6 *= 0.3f;
51361 num7 *= 0f;
51362 num8 *= 0.17f;
51363 break;
51364 case 5145:
51365 num6 *= 0.3f;
51366 num7 *= 0f;
51367 num8 *= 0.35f;
51368 break;
51369 case 5146:
51370 num6 *= (float)Main.DiscoR / 255f;
51371 num7 *= (float)Main.DiscoG / 255f;
51372 num8 *= (float)Main.DiscoB / 255f;
51373 break;
51374 }
51375 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), num6, num7, num8);
51376 }
51377 else if (type == 282)
51378 {
51379 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.7f, 1f, 0.8f);
51380 }
51381 else if (type == 286)
51382 {
51383 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.7f, 0.8f, 1f);
51384 }
51385 else if (type == 3112)
51386 {
51387 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1f, 0.6f, 0.85f);
51388 }
51389 else if (type == 4776)
51390 {
51391 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.7f, 0f, 1f);
51392 }
51393 else if (type == 3002)
51394 {
51395 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 1.05f, 0.95f, 0.55f);
51396 }
51397 else if (type == 331)
51398 {
51399 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.55f, 0.75f, 0.6f);
51400 }
51401 else if (type == 183)
51402 {
51403 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.15f, 0.45f, 0.9f);
51404 }
51405 else if (type == 75)
51406 {
51407 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.8f, 0.7f, 0.1f);
51408 if (timeSinceItemSpawned % 12 == 0)
51409 {
51410 Dust dust = Dust.NewDustPerfect(base.Center + new Vector2(0f, (float)height * 0.2f) + Main.rand.NextVector2CircularEdge(width, (float)height * 0.6f) * (0.3f + Main.rand.NextFloat() * 0.5f), 228, (Vector2?)new Vector2(0f, (0f - Main.rand.NextFloat()) * 0.3f - 1.5f), 127, default(Color), 1f);
51411 dust.scale = 0.5f;
51412 dust.fadeIn = 1.1f;
51413 dust.noGravity = true;
51414 dust.noLight = true;
51415 }
51416 }
51417 else if (ItemID.Sets.BossBag[type])
51418 {
51419 Lighting.AddLight((int)((position.X + (float)width) / 16f), (int)((position.Y + (float)(height / 2)) / 16f), 0.4f, 0.4f, 0.4f);
51420 if (timeSinceItemSpawned % 12 == 0)
51421 {
51422 Dust dust2 = Dust.NewDustPerfect(base.Center + new Vector2(0f, (float)height * -0.1f) + Main.rand.NextVector2CircularEdge((float)width * 0.6f, (float)height * 0.6f) * (0.3f + Main.rand.NextFloat() * 0.5f), 279, (Vector2?)new Vector2(0f, (0f - Main.rand.NextFloat()) * 0.3f - 1.5f), 127, default(Color), 1f);
51423 dust2.scale = 0.5f;
51424 dust2.fadeIn = 1.1f;
51425 dust2.noGravity = true;
51426 dust2.noLight = true;
51427 dust2.alpha = 0;
51428 }
51429 }
51430 }
bool wet
The Entity is currently in water. Projectile: Affects movement speed and some projectiles die when ...
Definition Entity.cs:57
Vector2 position
The position of this Entity in world coordinates.
Definition Entity.cs:28
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
static bool[] Torches
If true for a given item type (F:Terraria.Item.type), then that item is a torch. Torches can be aut...
Definition ItemID.cs:1539
static bool[] WaterTorches
If true for a given item type (F:Terraria.Item.type), then that item is a water torch....
Definition ItemID.cs:1546
static bool[] BossBag
Set for all boss bags. Causes bags to drop dev armor and creates a glow around the item when dropped ...
Definition ItemID.cs:1565
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
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
Color color
Draws the item sprite with a colored tint. Gel and Sharkfin use this to spawn different colored items...
Definition Item.cs:506
int timeSinceItemSpawned
A value that increases every tick an item is in the world. Defaults to the value in F:Terraria....
Definition Item.cs:196
int type
The Item ID of this item. The Item ID is a unique number assigned to each Item loaded into the game....
Definition Item.cs:345

References Terraria.Lighting.AddLight(), Terraria.ID.ItemID.Sets.BossBag, Terraria.Item.color, Terraria.Item.createTile, Terraria.Main.demonTorch, Terraria.Main.DiscoB, Terraria.Main.DiscoG, Terraria.Main.DiscoR, Terraria.Main.dust, Terraria.Main.essScale, Terraria.Entity.height, Terraria.Dust.NewDust(), Terraria.Dust.NewDustPerfect(), Terraria.Item.placeStyle, Terraria.Entity.position, Terraria.Main.rand, Terraria.Item.timeSinceItemSpawned, Terraria.ID.ItemID.Sets.Torches, Terraria.Item.type, Terraria.ID.ItemID.Sets.WaterTorches, Terraria.Entity.wet, and Terraria.Entity.width.

Referenced by Terraria.Item.UpdateItem().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: