Skip to content

Commit

Permalink
Removed unused extension
Browse files Browse the repository at this point in the history
  • Loading branch information
Michal78900 committed Jul 19, 2021
1 parent eee898f commit 2b2a318
Showing 1 changed file with 0 additions and 25 deletions.
25 changes: 0 additions & 25 deletions MapEditorReborn/API/Extenstions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -123,31 +123,6 @@ public static DoorType GetDoorTypeByName(this DoorVariant doorVariant)
}
}

/// <summary>
/// Converts a <see cref="DoorVariant"/> into a <see cref="DoorObject"/>.
/// </summary>
/// <param name="door">The <see cref="DoorVariant"/> which should be converted.</param>
/// <returns><see cref="DoorObject"/> which can be used to spawn a door or saving it to a file.</returns>
public static DoorObject ConvertToDoorObject(this DoorVariant door)
{
Room room = Map.FindParentRoom(door.gameObject);
BreakableDoor breakableDoor = door as BreakableDoor;
DoorObjectComponent doorObjectComponent = door.GetComponent<DoorObjectComponent>();

return new DoorObject(
door.GetDoorTypeByName(),
door.transform.position,
door.transform.eulerAngles,
door.transform.localScale,
room.Type,
door.NetworkTargetState,
door.NetworkActiveLocks == 64,
door.RequiredPermissions.RequiredPermissions,
breakableDoor._ignoredDamageSources,
breakableDoor._maxHealth,
doorObjectComponent.OpenOnWarheadActivation);
}

public static string ConvertToSpawnPointTag(this RoleType roleType)
{
switch (roleType)
Expand Down

0 comments on commit 2b2a318

Please sign in to comment.