3 string m_NewItemTypeName =
"Fireplace";
14 Object target_object = target.GetObject();
17 if ( target_object && target_object.IsFireplace() )
19 OvenIndoor fireplace_indoor = OvenIndoor.Cast( target_object );
21 if ( fireplace_indoor && !fireplace_indoor.HasAshes() && !fireplace_indoor.IsBurning() && fireplace_indoor.IsCargoEmpty() && !fireplace_indoor.DirectCookingSlotsInUse() )
24 bool found = player.GetInventory().FindFirstFreeLocationForNewEntity( m_NewItemTypeName,
FindInventoryLocationType.ANY, targetIL );
32 override void OnExecuteServer(
ActionData action_data )
34 Object target_object = action_data.m_Target.GetObject();
35 OvenIndoor fireplace_indoor = OvenIndoor.Cast( target_object );
39 bool found = action_data.m_Player.GetInventory().FindFirstFreeLocationForNewEntity( m_NewItemTypeName,
FindInventoryLocationType.ANY, targetIL );
43 lambda.OverrideNewLocation( targetIL );
44 action_data.m_Player.ServerReplaceItemWithNew( lambda );
60 super.CopyOldPropertiesToNew( old_item, new_item );
62 MiscGameplayFunctions.TransferInventory(old_item, new_item,
m_Player);