Maybe finished taxi job
This commit is contained in:
@@ -251,8 +251,23 @@ namespace ReallifeGamemode.Server.Managers
|
||||
[RemoteEvent("CLIENT:InteractionMenu_CallService_Taxi")]
|
||||
public void CallServiceTaxi(Client player, string street, string zone)
|
||||
{
|
||||
string msg = $"!{{02FCFF}}{player.Name} hat in der {street} in {zone} ein Taxi gerufen.";
|
||||
ChatService.BroadcastJob(msg, JobManager.GetJob<TaxiDriverJob>());
|
||||
var taxiJob = JobManager.GetJob<TaxiDriverJob>();
|
||||
|
||||
if(taxiJob.TaxiContracts.Where(t => t.Name == player.Name).Count() != 0)
|
||||
{
|
||||
ChatService.Error(player, "Du kannst nur einmal ein Taxi rufen");
|
||||
return;
|
||||
}
|
||||
|
||||
taxiJob.TaxiContracts.Add(new TaxiContract()
|
||||
{
|
||||
Name = player.Name,
|
||||
Position = player.Position
|
||||
});
|
||||
|
||||
string msg = $"!{{02FCFF}}{player.Name} hat in der Straße {street} in {zone} ein Taxi gerufen.";
|
||||
ChatService.BroadcastJob(msg, taxiJob);
|
||||
player.SendChatMessage("!{02FCFF}Du hast erfolgreich ein Taxi zu deiner aktuellen Position gerufen.");
|
||||
}
|
||||
#endregion
|
||||
#region Spielerinteraktionen PFEILTASTE-LINKS
|
||||
|
||||
Reference in New Issue
Block a user