teleport items
This commit is contained in:
parent
ba90d5227c
commit
76dc99eb62
@ -9,7 +9,13 @@ namespace TarkovHax
|
|||||||
{
|
{
|
||||||
public class TarkovHaxBehaviour : MonoBehaviour
|
public class TarkovHaxBehaviour : MonoBehaviour
|
||||||
{
|
{
|
||||||
|
public TarkovHaxBehaviour()
|
||||||
|
{
|
||||||
|
_randomizer = new System.Random();
|
||||||
|
}
|
||||||
|
|
||||||
public GameObject GameObjectHolder;
|
public GameObject GameObjectHolder;
|
||||||
|
private System.Random _randomizer;
|
||||||
|
|
||||||
private IEnumerable<Player> _players;
|
private IEnumerable<Player> _players;
|
||||||
private IEnumerable<LootableContainer> _lootableContainers;
|
private IEnumerable<LootableContainer> _lootableContainers;
|
||||||
@ -24,6 +30,8 @@ namespace TarkovHax
|
|||||||
|
|
||||||
private float _maxDrawingDistance = 15000f;
|
private float _maxDrawingDistance = 15000f;
|
||||||
|
|
||||||
|
private string _magicAppDomainString = "mvhYQbbHjrHM";
|
||||||
|
|
||||||
public void Load()
|
public void Load()
|
||||||
{
|
{
|
||||||
GameObjectHolder = new GameObject();
|
GameObjectHolder = new GameObject();
|
||||||
@ -54,7 +62,7 @@ namespace TarkovHax
|
|||||||
}
|
}
|
||||||
if (Input.GetKeyDown(KeyCode.Keypad1))
|
if (Input.GetKeyDown(KeyCode.Keypad1))
|
||||||
{
|
{
|
||||||
ToggleNightVision();
|
TeleportItemsToPlayer();
|
||||||
}
|
}
|
||||||
if (Input.GetKeyDown(KeyCode.KeypadPlus))
|
if (Input.GetKeyDown(KeyCode.KeypadPlus))
|
||||||
{
|
{
|
||||||
@ -76,7 +84,6 @@ namespace TarkovHax
|
|||||||
Camera.main.fieldOfView -= 1f;
|
Camera.main.fieldOfView -= 1f;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void OpenDoors()
|
private void OpenDoors()
|
||||||
{
|
{
|
||||||
var doors = FindObjectsOfType<Door>();
|
var doors = FindObjectsOfType<Door>();
|
||||||
@ -89,24 +96,22 @@ namespace TarkovHax
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//private bool _nightVisionOn = false;
|
private void TeleportItemsToPlayer()
|
||||||
private void ToggleNightVision()
|
|
||||||
{
|
{
|
||||||
//var camera = (PlayerCameraController)FindObjectOfType(typeof(PlayerCameraController));
|
var lootItems = FindObjectsOfType<LootItem>();
|
||||||
//if (_nightVisionOn)
|
float xOffset = 0f;
|
||||||
//{
|
float yOffset = 0f;
|
||||||
// var component = camera.gameObject.AddComponent<NightVision>();
|
foreach (var lootItem in lootItems)
|
||||||
// if (component != null)
|
{
|
||||||
// {
|
var newPosition = new Vector3(
|
||||||
// DestroyImmediate(component);
|
Camera.main.transform.position.x + xOffset,
|
||||||
// }
|
Camera.main.transform.position.y,
|
||||||
//}
|
Camera.main.transform.position.z + yOffset);
|
||||||
//else
|
|
||||||
//{
|
|
||||||
// camera.gameObject.AddComponent<NightVision>();
|
|
||||||
//}
|
|
||||||
|
|
||||||
//_nightVisionOn = !_nightVisionOn;
|
lootItem.transform.position = newPosition;
|
||||||
|
xOffset += 0.1f;
|
||||||
|
yOffset += 0.1f;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void OnGUI()
|
private void OnGUI()
|
||||||
@ -117,7 +122,7 @@ namespace TarkovHax
|
|||||||
}
|
}
|
||||||
|
|
||||||
GUI.color = Color.red;
|
GUI.color = Color.red;
|
||||||
GUI.Label(new Rect(10f, 10f, 100f, 50f), "tarkov h4x");
|
GUI.Label(new Rect(10f, 10f, 1000f, 500f), "tarkov h4x");
|
||||||
|
|
||||||
if (_showPlayersESP && Time.time >= _playersNextUpdateTime)
|
if (_showPlayersESP && Time.time >= _playersNextUpdateTime)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user