10 override bool IsElectricAppliance()
17 TurnOnItem( m_AttachedTo );
23 TurnOffItem( m_AttachedTo );
31 m_AttachedTo = parent;
34 if ( GetCompEM().IsPlugged() )
36 parent.SetAnimationPhase(
"Cord_plugged", 0);
37 parent.SetAnimationPhase(
"Cord_folded", 1);
41 parent.SetAnimationPhase(
"Cord_plugged", 1);
42 parent.SetAnimationPhase(
"Cord_folded", 0);
46 void DetachFromObject(
ItemBase parent)
52 GetCompEM().UnplugThis();
59 if ( GetCompEM().IsWorking() )
61 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"dz\\gear\\camping\\data\\christmas_lights_red_on.rvmat" );
62 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"dz\\gear\\camping\\data\\christmas_lights_green_on.rvmat" );
63 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"dz\\gear\\camping\\data\\christmas_lights_blue_on.rvmat" );
64 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"dz\\gear\\camping\\data\\christmas_lights_yellow_on.rvmat" );
65 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
66 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
67 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
68 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
82 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"dz\\gear\\camping\\data\\christmass_ligths_string.rvmat" );
83 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"dz\\gear\\camping\\data\\christmass_ligths_string.rvmat" );
84 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"dz\\gear\\camping\\data\\christmass_ligths_string.rvmat" );
85 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"dz\\gear\\camping\\data\\christmass_ligths_string.rvmat" );
86 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
87 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
88 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
89 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"dz\\gear\\camping\\data\\christmas_lights_string_ca.paa" );
96 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"" );
97 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"" );
98 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"" );
99 item.SetObjectMaterial( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"" );
100 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_r"),
"" );
101 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_g"),
"" );
102 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_b"),
"" );
103 item.SetObjectTexture( item.GetHiddenSelectionIndex(
"xlights_glass_y"),
"" );
105 item.SetAnimationPhase(
"Cord_plugged", 1);
106 item.SetAnimationPhase(
"Cord_folded", 1);