-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathInteriorLoader.cs
74 lines (56 loc) · 2.13 KB
/
InteriorLoader.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
using BrokeProtocolClient.settings;
using BrokeProtocolClient.utils;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using UnityEngine.SceneManagement;
namespace BrokeProtocolClient.modules.exploit
{
class InteriorLoader : Module
{
InputSetting interiorId = new InputSetting("Interior ID", 4, "0");
ActionSetting setButton;
ActionSetting currentButton;
ActionSetting allButton;
public InteriorLoader() : base(Categories.Exploit, "Interior Loader", "Loads specified interior")
{
addSetting(interiorId);
setButton = new ActionSetting("Set interior ID", SetInterior);
addSetting(setButton);
currentButton = new ActionSetting("Curren interior", CurrentInterior);
addSetting(currentButton);
allButton = new ActionSetting("All interiors", AllInteriors);
addSetting(allButton);
}
public override void onActivate()
{
}
public override void onDeactivate()
{
}
public override void onRender()
{
}
public override void onUpdate()
{
}
private void SetInterior()
{
getClient().SceneManager.SetInterior(Int32.Parse(interiorId.getValue()));
}
private void CurrentInterior()
{
ConsoleBase.WriteLine($"Current interior:\nName: {getClient().SceneManager.mTransform.GetChild(getClient().SceneManager.currentInterior).name} ID: {getClient().SceneManager.currentInterior}");
}
private void AllInteriors()
{
ConsoleBase.WriteLine($"All interiors:");
for (int i = 0; i < getClient().SceneManager.mTransform.childCount; i++)
{
ConsoleBase.WriteLine($"Name: {getClient().SceneManager.mTransform.GetChild(i).name} ID: {getClient().SceneManager.mTransform.GetChild(i).GetSiblingIndex()}");
}
}
}
}