Skip to content

refactor!: rename spawn/destroy register/unregister methods of networkspawnmanager #551

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public static void RegisterSpawnHandler(ulong prefabHash, SpawnHandlerDelegate h
/// </summary>
/// <param name="prefabHash">The prefab hash to destroy</param>
/// <param name="handler">The delegate handler</param>
public static void RegisterCustomDestroyHandler(ulong prefabHash, DestroyHandlerDelegate handler)
public static void RegisterDestroyHandler(ulong prefabHash, DestroyHandlerDelegate handler)
{
if (CustomDestroyHandlers.ContainsKey(prefabHash))
{
Expand All @@ -83,19 +83,19 @@ public static void RegisterCustomDestroyHandler(ulong prefabHash, DestroyHandler
}

/// <summary>
/// Removes the custom spawn handler for a specific prefab hash
/// Unregisters the custom spawn handler for a specific prefab hash
/// </summary>
/// <param name="prefabHash">The prefab hash of the prefab spawn handler that is to be removed</param>
public static void RemoveCustomSpawnHandler(ulong prefabHash)
public static void UnregisterSpawnHandler(ulong prefabHash)
{
CustomSpawnHandlers.Remove(prefabHash);
}

/// <summary>
/// Removes the custom destroy handler for a specific prefab hash
/// Unregisters the custom destroy handler for a specific prefab hash
/// </summary>
/// <param name="prefabHash">The prefab hash of the prefab destroy handler that is to be removed</param>
public static void RemoveCustomDestroyHandler(ulong prefabHash)
public static void UnregisterDestroyHandler(ulong prefabHash)
{
CustomDestroyHandlers.Remove(prefabHash);
}
Expand Down Expand Up @@ -743,4 +743,4 @@ internal static void OnDestroyObject(ulong networkId, bool destroyGameObject)
}
}
}
}
}