Skip to content
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

More random events #5825

Merged
merged 1 commit into from
Jan 8, 2021
Merged
Show file tree
Hide file tree
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

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions UnityProject/Assets/Scripts/Core/Chat/Chat.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,17 @@ public static void InvokeChatEvent(ChatEvent chatEvent)
continue;
}

// A temporary solution until proper telecomms is implemented
if (Channels.RadioChannels.HasFlag(channel))
{
if (InGameEvents.EventCommsBlackout.CommsDown) return;

if (InGameEvents.EventProcessorOverload.ProcessorOverload)
{
chatEvent.message = InGameEvents.EventProcessorOverload.ProcessMessage(chatEvent.message);
}
}

chatEvent.channels = channel;
Instance.addChatLogServer.Invoke(chatEvent);
discordMessageBuilder.Append($"[{channel}] ");
Expand Down
7 changes: 7 additions & 0 deletions UnityProject/Assets/Scripts/Core/Chat/ChatEvent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,13 @@ public enum ChatChannel
[Description("")] Blob = 1 << 20
}

public static class Channels
{
public static ChatChannel RadioChannels = ChatChannel.Common | ChatChannel.Command | ChatChannel.Syndicate
| ChatChannel.Engineering | ChatChannel.Supply | ChatChannel.Medical
| ChatChannel.Science | ChatChannel.Security | ChatChannel.Service;
}

/// <summary>
/// A set of flags to show active chat modifiers. Be aware this can contain multiple active chat modifiers at once!
/// </summary>
Expand Down
2 changes: 1 addition & 1 deletion UnityProject/Assets/Scripts/Core/Lighting/LightSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class LightSource : ObjectTrigger, ICheckedInteractable<HandApply>, IAPCP

private ItemTrait traitRequired;
private GameObject itemInMount;
private float integrityThreshBar;
public float integrityThreshBar { get; private set; }

[SerializeField]
private MultitoolConnectionType conType = MultitoolConnectionType.LightSwitch;
Expand Down
Loading