From a68bc2fe48aebf8afc1d36c03300f1c5bd9e4aed Mon Sep 17 00:00:00 2001
From: Yonatan Mark Liudmirsky <45634836+YonLiud@users.noreply.github.com>
Date: Thu, 4 Feb 2021 13:16:13 +0200
Subject: [PATCH] 4221 Patch & Update
---
EmergencyCallerClient/Client.cs | 17 +++++++----
.../EmergencyCallerClient.csproj | 8 +++--
.../EmergencyCallerServer.csproj | 5 ++--
README.md | 30 +++++++++++--------
4 files changed, 37 insertions(+), 23 deletions(-)
diff --git a/EmergencyCallerClient/Client.cs b/EmergencyCallerClient/Client.cs
index a39522b..6c7f153 100644
--- a/EmergencyCallerClient/Client.cs
+++ b/EmergencyCallerClient/Client.cs
@@ -65,20 +65,27 @@ private void OnClientResourceStart(string resourceName)
Debug.WriteLine(text);
string playername = Game.Player.Name;
TriggerServerEvent("sent911", playername, text, Game.PlayerPed.Position);
- cooldown();
+ cooldown(); // 🡠remove this line to disable cooldown
}), false);
}
private void OnRecieve911(string name, string args, Vector3 location)
{
string street = World.GetStreetName(location);
+ SendMessage(name, args, street); // 🡠remove line to disbale 911 message
+ MakeBlip(location, name); // 🡠remove line to disable blip
+ }
+ private void SendMessage(string name, string args, string street)
+ {
TriggerEvent("chat:addMessage", new
{
color = new[] { 0, 204, 204 },
multiline = true,
- args = new[] { "911", $"Caller: ^*{name} | Location: {street} | ^*Transcript: {args}" }
+ args = new[] { "911", $"^4Caller: ^0^*{name} | ^4Location: ^0{street} | ^4^*Transcript: ^0{args}" }
});
+ }
+ private void MakeBlip(Vector3 location, string name)
+ {
Blip blip = World.CreateBlip(location);
-
blip.Sprite = BlipSprite.ArmoredTruck;
blip.Color = BlipColor.Blue;
blip.Name = $"{name}'s Emergency Call";
@@ -86,14 +93,14 @@ private void OnRecieve911(string name, string args, Vector3 location)
}
private async void removeBlip(Blip blip)
{
- await Delay(60000);
+ await Delay(60000); // 🡠change this to the amount of exparation
blip.Delete();
}
private async void cooldown()
{
onCooldown = true;
Debug.WriteLine("Cooldown Set");
- await Delay(15000);
+ await Delay(15000); // 🡠change this to the amount of delay between calls
onCooldown = false;
Debug.WriteLine("Your Cooldown has expired");
diff --git a/EmergencyCallerClient/EmergencyCallerClient.csproj b/EmergencyCallerClient/EmergencyCallerClient.csproj
index 12b52f7..640cc95 100644
--- a/EmergencyCallerClient/EmergencyCallerClient.csproj
+++ b/EmergencyCallerClient/EmergencyCallerClient.csproj
@@ -31,9 +31,11 @@
4
-
- False
- D:\Games\FiveM\FiveM.app\citizen\clr2\lib\mono\4.5\CitizenFX.Core.dll
+
+ B:\Games\FiveM\FiveM.app\citizen\clr2\lib\mono\4.5\CitizenFX.Core.dll
+
+
+ B:\Games\FiveM\FiveM.app\citizen\clr2\lib\mono\4.5\CitizenFX.Core.Client.dll
diff --git a/EmergencyCallerServer/EmergencyCallerServer.csproj b/EmergencyCallerServer/EmergencyCallerServer.csproj
index 6a37cd0..cf017ed 100644
--- a/EmergencyCallerServer/EmergencyCallerServer.csproj
+++ b/EmergencyCallerServer/EmergencyCallerServer.csproj
@@ -31,9 +31,8 @@
4
-
- False
- ..\FXServer\citizen\clr2\lib\mono\4.5\CitizenFX.Core.dll
+
+ B:\FXServer\citizen\clr2\lib\mono\4.5\CitizenFX.Core.dll
diff --git a/README.md b/README.md
index 20746bf..3bc74c2 100644
--- a/README.md
+++ b/README.md
@@ -2,15 +2,30 @@
Emergency Caller is a C# Script for [FiveM](https://fivem.net/).
-Emergency Caller allows the players inside the session to call Police/EMS for a Roleplay Scene. Emergency Caller will display the message of the calling suspect in chat and will create a temporary blips on map to ease on the officers to locate the caller
+Emergency Caller allows the players inside the session to call 911 for a Roleplay Scene. Emergency Caller will display the message of the calling suspect in chat and will create a temporary blips on map to ease on the officers to locate the caller
## Download
[Click Here To Download](https://github.com/YonLiud/Emergency-Caller/releases/)
+
NEW! UK Version (999) [Source is unavailable]
+## Screenshots
-## Installation
+#### Chat Message:
+![chat message](https://upload.vaa.red/i/EZvSY.png)
+
+#### Map Blip:
+![map image](https://upload.vaa.red/i/oAsGV.png)
+
+#### Description in Map:
+![desc](https://upload.vaa.red/i/YVHFR.png)
+#### Cooldown Message (Visible only on client side):
+![err](https://upload.vaa.red/i/2u5nkM.png)
+
+
+## Installation
+
1) Inside your server.cfg, type the following command:
```
@@ -37,13 +52,4 @@ If you have any suggestions or ideas, feel free to contact me by my Discord
To report a bug or any issue you encounter, open a github issue ticket, and I will fix the issue hopefully the following commit and releases
## Authors and acknowledgment
-Created by Yonatan Mark Liudmirsky
-
-
-
-## License
-[MIT](https://choosealicense.com/licenses/mit/)
-
-## Project Status
-
-Emergency Caller is currently in development and is a work in progress, everything in the project is a subject to get removed or changed
+Created by [@YonLiud](https://github.com/YonLiud)
\ No newline at end of file