corvex seine sachen drauf + hitmarker test

This commit is contained in:
michael.reiswich
2021-06-06 14:28:53 +02:00
parent c5879911a2
commit 376e5e9a1a
5 changed files with 356 additions and 0 deletions

View File

@@ -0,0 +1,19 @@
using GTANetworkAPI;
public class vMachnesRemote : Script
{
//IMPORTANT: THIS EVENT IS REQUIRED!
[RemoteEvent("vendingMachine.Remote.SharedData")]
public void UpdatePlayerData(Player player, string key, object data)
{
player.SetSharedData(key, data);
}
//This event gets fired once the Animation finished playing. You can for example use it, to give a Player Health etc.
[RemoteEvent("vendingMachines.Remote.Finish")]
public void OnVendingMachineInteractionFinish(Player player)
{
var health = (player.Health + 25 < 100 ? player.Health + 25 : 100);
NAPI.Player.SetPlayerHealth(player, health);
}
}