-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTinkerScripts.lua
More file actions
4288 lines (3712 loc) · 176 KB
/
Copy pathTinkerScripts.lua
File metadata and controls
4288 lines (3712 loc) · 176 KB
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
--[[
This file is part of TinkerScripts.
Copyright (C) 2026 ImagineNothing
TinkerScripts is free software. You can redistribute it and/or modify it
under the terms of the GNU GPLv3 (or later), as published by the Free Software Foundation:
see LICENSE or <https://www.gnu.org/licenses/> for all the details.
]]
natives.load_natives()
local cls = " \r"
local lual = "\r\27[9C]\27[94m[INFO/LuaScript]\27[m "
local lual_s = ": \27[92mInitialized successfully\27[m "
local function IsOnline() return NETWORK.NETWORK_IS_SESSION_STARTED() and not NETWORK.NETWORK_IS_IN_TRANSITION() and not STREAMING.IS_PLAYER_SWITCH_IN_PROGRESS() and not NETWORK.NETWORK_IS_ACTIVITY_SESSION() end
---|| Submenu ||----------------------------------------------------------------------------------
local TS_BUILD = "1158.16"
local versionPtrn = memory.scan_pattern("4C 8D 0D ? ? ? ? 48 8D 5C 24 ? 48 89 D9 48 89 FA") -- from the menu
local GameVersion = versionPtrn:add(3):rip():get_string()
if GameVersion ~= TS_BUILD then
notify.error("TinkeScripts - WRONG GAME BUILD", string.format("TinkeScripts: %s\nCurrent Game Build: %s", TS_BUILD, GameVersion))
log.error(string.format("\27[2A]\r\27[18C\27[31m[EROR/LuaScript]\27[m TinkerScripts: WRONG GAME BUILD: %s | TinkeScripts: %s %s\27[B] %s \27[2A", GameVersion, TS_BUILD, cls, cls)) return
end
local TinkerPath = FileMgr.GetMenuRootPath()
local TS_PATH_Blips = FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/Blips.lua") load(TS_PATH_Blips)()
local TS_PATH_Unlocks = FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/TS_RecoveryPlus/Unlocks.lua") load(TS_PATH_Unlocks)()
local TS_PATH_Tunables = FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/TS_RecoveryPlus/Tunables.lua") load(TS_PATH_Tunables)()
local TS_PATH_FMCharTats = FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/HumanCanvas/FMCharTats.lua") load(TS_PATH_FMCharTats)()
local function TS_PATH_Settings() return FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/Settings/TS_Settings.lua") end load(TS_PATH_Settings())()
local function TS_PATH_FMCharTatCombo() return FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/HumanCanvas/Exported_TattooCombo.txt") end
local function TS_PATH_NoCloudSave() return FileMgr.ReadFileContent(TinkerPath.."/TinkerScripts/Settings/BlockCloudSaves/NoSave.txt") end
menu.set_menu_icon("\xef\x81\xae\xef\x81\xae")
local Tinker = menu.get_submenu("TinkerScripts")
local TS_Main = Tinker:add_category("Main")
local TS_Bizteroids = Tinker:add_category("Biz-Teroids")
local TS_PhoneMaster = Tinker:add_category("Phone Master")
local TS_GoonVan = Tinker:add_category("Gun Van Halen")
local TS_RainbowVeh = Tinker:add_category("Rainbow Vehicles")
local TS_RecoveryPlus = Tinker:add_category("Recovery +")
local TS_SettingsPlus = Tinker:add_category("Settings +")
function FindNewSession()
ScriptFunction("shop_controller", ScriptPointer("SendToClouds", "2D 00 02 00 00 72 5D ? ? ? 72")):call("") -- CALLTHEFUNCTIONCALLTHEFUNCTIONCALLTHEFUNCTION | from the menu
ScriptGlobal(1575048):set_int(11)
end
function CurPlayerCoords()
PlaCoords = ENTITY.GET_ENTITY_COORDS(PLAYER.PLAYER_PED_ID(), 0)
PlaHeading = ENTITY.GET_ENTITY_HEADING(PLAYER.PLAYER_PED_ID())
PlaFwdVec = ENTITY.GET_ENTITY_FORWARD_VECTOR(PLAYER.PLAYER_PED_ID())
end
function scripts.start_new_script(ScriptName, StackSize)
script.run_in_callback(function()
if scripts.is_active(ScriptName) then
scripts.run_as_script(ScriptName, function() SCRIPT.TERMINATE_THIS_THREAD() end)
end
SCRIPT.REQUEST_SCRIPT(ScriptName)
script.yield(50)
if SCRIPT.HAS_SCRIPT_LOADED(ScriptName) then
BUILTIN.START_NEW_SCRIPT(ScriptName, StackSize)
SCRIPT.SET_SCRIPT_AS_NO_LONGER_NEEDED(ScriptName)
end
end)
end
local screenX, screenY = ImGui.GetDisplaySize()
local nomoretreeplease = util.time()
local function CenteredText(Text, NewSeparator, FakeSeparatorText)
if not FakeSeparatorText then
ImGui.SetCursorPosX((ImGui.GetWindowWidth() - ImGui.CalcTextSize(Text)) / 2)
ImGui.TextDisabled(Text)
if NewSeparator then ImGui.Separator() end
else
ImGui.SeparatorText("")
ImGui.SameLine()
ImGui.SetCursorPosX((ImGui.GetWindowWidth() - ImGui.CalcTextSize(Text)) / 2)
ImGui.Text(Text)
end
end
local function TpToBlip(KillDelPed, Blip, BEntity)
if KillDelPed then
script.run_in_callback(function()
for _, MissionEnemy in ipairs(entities.get_all_peds_as_handles()) do
if Ped(MissionEnemy):is_enemy() then
Entity(MissionEnemy):kill()
end
end
script.yield(300)
for _, MissionEnemy in ipairs(entities.get_all_peds_as_handles()) do
if Ped(MissionEnemy):is_dead() then
Entity(MissionEnemy):delete()
end
end
end)
end
local BlipID = HUD.GET_FIRST_BLIP_INFO_ID(Blip)
if BEntity then
local BlipH = HUD.GET_BLIP_INFO_ID_ENTITY_INDEX(BlipID)
if Entity(BlipH):is_valid() then
local BEntityPos = Entity(BlipH):get_position()
PED.SET_PED_COORDS_KEEP_VEHICLE(PLAYER.PLAYER_PED_ID(), BEntityPos.x, BEntityPos.y, BEntityPos.z + 0.5)
--else
-- notify.error("TinkerScript - Teleport to Blip", "No coordinates available!", 3000)
end
else
if HUD.DOES_BLIP_EXIST(BlipID) then
local blip_coords = HUD.GET_BLIP_INFO_ID_COORD(BlipID)
PED.SET_PED_COORDS_KEEP_VEHICLE(PLAYER.PLAYER_PED_ID(), blip_coords.x, blip_coords.y, blip_coords.z + 0.5)
--else
-- notify.error("TinkerScript - Teleport to Blip", "No coordinates available!", 3000)
end
end
end
local function TpToEntity(EntityModel)
script.run_in_callback(function()
for _, h in ipairs(entities.get_all_objects_as_handles()) do
if Entity(h):get_model() == EntityModel then
local EntityCoords = Entity(h):get_position()
PED.SET_PED_COORDS_KEEP_VEHICLE(PLAYER.PLAYER_PED_ID(), EntityCoords.x, EntityCoords.y, EntityCoords.z + 0.5) break
end
end
end)
end
---|| Main ||------------------------------------------------------------------------------
local LocationCoords = { -- some from rage.mp
{ LocName = "Franklin's Aunt's House", LocDesc = "Teleport to Franklin's Aunt's House", LocCoords = {-17.95, -1440.61, 31.10} },
{ LocName = "Franklin's House", LocDesc = "Teleport to Franklin's House", LocCoords = {7.61, 538.30, 176.03} },
{ LocName = "Michael's House", LocDesc = "Teleport to Michael's House", LocCoords = {-815.44, 178.77, 72.15} },
{ LocName = "Trevor's Trailer", LocDesc = "Teleport to Trevor's Trailer", LocCoords = {1972.90, 3816.28, 33.42} },
{ LocName = "Match Winner Room", LocDesc = "Teleport to Match \"WINNER\" Room", LocCoords = {414.4, -977.6, -100.0042} },
{ LocName = "Character Creation Room", LocDesc = "Teleport to Character Creation/Selection Room", LocCoords = {409.13, -999.44, -99.00} },
{ LocName = "Height Messure", LocDesc = "Teleport to Character Height Messure", LocCoords = {402.91, -996.90, -99.00} },
{ LocName = "Omega's Garage", LocDesc = "Teleport to Omega's Garage", LocCoords = {2331.344, 2574.073, 46.68137} },
{ LocName = "Lester's House", LocDesc = "Teleport to Lester's House", LocCoords = {1273.9, -1719.305, 54.77141} },
{ LocName = "Torture Room", LocDesc = "Teleport to Torture Room", LocCoords = {136.5146, -2203.149, 7.30914} },
{ LocName = "Split-Sides Comedy Club", LocDesc = "Teleport to Split-Sides Comedy Club", LocCoords = {382.71, -1001.45, -99.00} },
{ LocName = "Motel", LocDesc = "Teleport to Motel", LocCoords = {152.2605,-1004.471, -98.99999} },
{ LocName = "FIB Building", LocDesc = "Teleport to FIB Building", LocCoords = {134.5835,-749.339, 258.152} },
{ LocName = "IAA Office", LocDesc = "Teleport to IAA Office", LocCoords = {117.22,-620.938, 206.1398} }
}
local function FastRespawn()
local logresp = {
"Wasted Screen Skipped!",
"Player Respawned a thousand times!",
"Fast-Respawn!",
"mp_forcerespawnpla... oops, wrong game.",
"Had to make the script longer somehow.",
"I Need Healing!",
"I should be playing Warframe...",
"Wanna play RnG?",
"I will not die; not yet, amigo!", -- Skye main since beta btw
"Kifflom!",
--"Moar text"
}
if ScriptGlobal(2658296):at(PLAYER.PLAYER_ID(), 468):at(236):get_int() == -1 then
CurPlayerCoords()
ScriptGlobal(2635562 + 2924):set_int(1)
--log.info(cls..lual.."Rejack: "..logresp[math.random(#logresp)]..cls)
script.yield(1500)
PED.SET_PED_COORDS_KEEP_VEHICLE(PLAYER.PLAYER_PED_ID(), PlaCoords.x, PlaCoords.y, PlaCoords.z)
ENTITY.SET_ENTITY_HEADING(PLAYER.PLAYER_PED_ID(), PlaHeading)
end
end
local function FastReload()
if PAD.IS_CONTROL_JUST_PRESSED(0, 24) then
local cur_weap = WEAPON.GET_SELECTED_PED_WEAPON(PLAYER.PLAYER_PED_ID())
script.yield(20)
WEAPON.SET_CURRENT_PED_WEAPON(PLAYER.PLAYER_PED_ID(), "WEAPON_STICKYBOMB", 0)
script.yield(200)
WEAPON.SET_CURRENT_PED_WEAPON(PLAYER.PLAYER_PED_ID(), cur_weap, 1)
end
end
local function ClearWorld(CwToggle)
ScriptGlobal(1690468):set_int(CwToggle) -- 1 is the minimum, 0 resets back to default value
ScriptGlobal(1690469):set_int(CwToggle)
ScriptGlobal(1690470):set_int(CwToggle)
end
local function GlobalSetBit(global, bitonoff, bits)
local bitvalue = global:get_int()
local togglebit = bitonoff
if togglebit == 1 then
bitvalue = bit.bor(bitvalue, bit.lshift(1, bits))
elseif togglebit == 0 then
bitvalue = bit.band(bitvalue, bit.bnot(bit.lshift(1, bits)))
end
global:set_int(bitvalue)
end
local function LocalSetBit(sLocal, bitonoff, bits)
local bitvalue = sLocal:get_int()
local togglebit = bitonoff
if togglebit == 1 then
bitvalue = bit.bor(bitvalue, bit.lshift(1, bits))
elseif togglebit == 0 then
bitvalue = bit.band(bitvalue, bit.bnot(bit.lshift(1, bits)))
end
sLocal:set_int(bitvalue)
end
local function RagdollPlayer()
if PAD.IS_CONTROL_PRESSED(0, 19) then
PED.SET_PED_TO_RAGDOLL(PLAYER.PLAYER_PED_ID(), 2000, 2000, 0, 0, 0, 0)
end
end
commandmgr.add_looped_command("fastrespawn", "Fast Respawn", "Skips the WASTED screen.", function()
FastRespawn()
end, function()
ScriptGlobal(2709139):set_int(1)
notify.success("TinkerScript - Rejack", "Fast Respawn Enabled!", 3000)
end, function()
ScriptGlobal(2709139):set_int(0)
notify.info("TinkerScript - Rejack", "Fast Respawn Disabled.", 3000)
end)
commandmgr.add_looped_command("fastreload", "Fast Reload", "Similar to Fast Reload macros. (FIRST PERSON ONLY)", function()
FastReload()
end, function()
notify.success("TinkerScript - Fast Reload", "Fast Reload Enabled!", 3000)
end, function()
notify.info("TinkerScript - Fast Reload", "Fast Reload Disabled.", 3000)
end)
commandmgr.add_bool_command("notm25_bst", "Bullshark Testosterone", "Enables BST", false, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 1, 0)
notify.success("TinkerScript - BST", "BST Enabled!", 3000)
end, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 1, 2)
notify.info("TinkerScript - BST", "BST Disabled.", 3000)
end)
local m25_yogaRmulti = 1.15
local m25_yogaSmulti = 2.0
commandmgr.add_bool_command("m25_runboost", "Run/Swim Boost", "Enables Run/Swim Boost.\n*This is essentially the same as \"Super Run\" from Self submenu, but using a global (Not to be confused with \"Fast Run\" stat).", false, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 1, 10)
notify.success("TinkerScript - Run Boost", "Run Boost Enabled!", 3000)
end, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 0, 10)
notify.info("TinkerScript - Run Boost", "Run Boost Disabled.", 3000)
end)
commandmgr.add_bool_command("m25_strengthboost", "Strength Boost", "Enables Strength Boost", false, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 1, 6)
notify.success("TinkerScript - Strength Boost", "Strength Boost Enabled!", 3000)
end, function()
GlobalSetBit(ScriptGlobal(2673276 + 3768), 0, 6)
notify.info("TinkerScript - Strength Boost", "Strength Boost Disabled.", 3000)
end)
commandmgr.add_bool_command("clearworld", "Clear World", "Remove all peds and vehicles.", false, function()
ClearWorld(1)
notify.success("TinkerScript - Clear World", "Clear World Enabled!", 3000)
end, function()
ClearWorld(0)
notify.info("TinkerScript - Clear World", "Clear World Disabled.", 3000)
end)
commandmgr.add_looped_command("ragdoll", "Ragdoll", "Ragdoll on command by pressing [L-ALT]", function()
RagdollPlayer()
end, function()
notify.success("TinkerScript - Ragdoll", "Manual Ragdoll Enabled!", 3000)
end, function()
notify.info("TinkerScript - Ragdoll", "Manual Ragdoll Disabled.", 3000)
end)
commandmgr.add_looped_command("infcombatroll", "Infinite Combat Roll", "& No-Recoil/Spread ;)", function()
stats.set_int("MPX_SHOOTING_ABILITY", 500)
end, function()
notify.success("TinkerScript - Infinite Combat Roll", "Infinite Combat Roll Enabled!", 3000)
end, function()
notify.info("TinkerScript - Infinite Combat Roll", "Infinite Combat Roll Disabled.", 3000)
end)
commandmgr.add_looped_command("noidlecam", "Disable Idle Cam", "Disables Idle Cam.", CAMERA.INVALIDATE_IDLE_CAM)
local VehAutoDrive = {
Toggle = false,
Mode = 0,
Label = { "Normal", "Rushed", "GTA" },
Flag = { 443, 787118, 1076625980 }
}
VehAutoDrive.SkipRedLight = function(PlaVeh)
if VehAutoDrive.Flag[VehAutoDrive.Mode + 1] == 787118 and VEHICLE.IS_VEHICLE_STOPPED_AT_TRAFFIC_LIGHTS(PlaVeh) then
script.yield(4000)
TASK.SET_DRIVE_TASK_DRIVING_STYLE(PLAYER.PLAYER_PED_ID(), tonumber(bit.band(787118, bit.bnot(bit.lshift(1, 7)))))
script.yield(2000)
TASK.SET_DRIVE_TASK_DRIVING_STYLE(PLAYER.PLAYER_PED_ID(), 787118)
end
end
local AutoDriveSpeed = 40
local function SelfTaxi()
local PlaVeh = PED.GET_VEHICLE_PED_IS_IN(PLAYER.PLAYER_PED_ID(), false)
if PED.IS_PED_SITTING_IN_ANY_VEHICLE(PLAYER.PLAYER_PED_ID()) then
local wp_blip = HUD.GET_FIRST_BLIP_INFO_ID(8)
if not HUD.DOES_BLIP_EXIST(wp_blip) then
notify.info("TinkerScript - Self Taxi", "Please set a waypoint first.", 3000) return
end
local wp_coords = HUD.GET_BLIP_INFO_ID_COORD(wp_blip)
TASK.TASK_VEHICLE_DRIVE_TO_COORD(PLAYER.PLAYER_PED_ID(), PlaVeh, wp_coords.x, wp_coords.y, wp_coords.z, AutoDriveSpeed, 0, 0, VehAutoDrive.Flag[VehAutoDrive.Mode + 1], 10.0, 0)
notify.info("TinkerScript - Self Taxi", "Auto-Drive to Waypoint has started.", 3000)
while true do
VEHICLE.SET_VEHICLE_MAX_SPEED(PlaVeh, AutoDriveSpeed)
CurPlayerCoords()
local dist = BUILTIN.VDIST(PlaCoords.x, PlaCoords.y, PlaCoords.z, wp_coords.x, wp_coords.y, wp_coords.z)
if drivemodechanged then TASK.SET_DRIVE_TASK_DRIVING_STYLE(PLAYER.PLAYER_PED_ID(), VehAutoDrive.Flag[VehAutoDrive.Mode + 1]) end
VehAutoDrive.SkipRedLight(PlaVeh)
if dist < 70.0 then
TASK.CLEAR_PED_TASKS(PLAYER.PLAYER_PED_ID())
VEHICLE.BRING_VEHICLE_TO_HALT(PlaVeh, 3.0, 1, 0)
notify.success("TinkerScript - Self Taxi", "Destination reached.", 3000) return
end
if PAD.IS_CONTROL_JUST_PRESSED(0, 22) then -- SPACEBAR
notify.info("TinkerScript - Self Taxi", "Auto-Drive to Waypoint has been canceled.", 3000)
TASK.CLEAR_PED_TASKS(PLAYER.PLAYER_PED_ID()) return
end
script.yield(0)
end
else
notify.warn("TinkerScript - Self Taxi", "You are not in a vehicle.", 3000)
end
end
local function Wander() -- Shadow of The Collossus?
local PlaVeh = PED.GET_VEHICLE_PED_IS_IN(PLAYER.PLAYER_PED_ID(), false)
if PED.IS_PED_SITTING_IN_ANY_VEHICLE(PLAYER.PLAYER_PED_ID()) then
TASK.TASK_VEHICLE_DRIVE_WANDER(PLAYER.PLAYER_PED_ID(), PlaVeh, AutoDriveSpeed, VehAutoDrive.Flag[VehAutoDrive.Mode + 1])
notify.info("TinkerScript - Auto-Wander", "Auto-Wander has started.", 3000)
while true do
VEHICLE.SET_VEHICLE_MAX_SPEED(PlaVeh, AutoDriveSpeed)
if drivemodechanged then TASK.SET_DRIVE_TASK_DRIVING_STYLE(PLAYER.PLAYER_PED_ID(), VehAutoDrive.Flag[VehAutoDrive.Mode + 1]) end
VehAutoDrive.SkipRedLight(PlaVeh)
if PAD.IS_CONTROL_JUST_PRESSED(0, 22) then -- SPACEBAR
notify.info("TinkerScript - Auto-Wander", "You took the wheel.", 3000)
TASK.CLEAR_PED_TASKS(PLAYER.PLAYER_PED_ID()) return
end
script.yield(0)
end
else
notify.warn("TinkerScript - Auto-Wander", "You are not in a vehicle.", 3000)
end
end
local jr_radius = 10
local function Joyrider(jr_radius)
CurPlayerCoords()
local vehicle = VEHICLE.GET_RANDOM_VEHICLE_IN_SPHERE(PlaCoords.x, PlaCoords.y, PlaCoords.z, jr_radius, 0, 101247)
local drivernomore = VEHICLE.GET_PED_IN_VEHICLE_SEAT(vehicle, -1, 0)
if vehicle ~= 0 and not Vehicle(vehicle):is_seat_free(-1) then
Entity(drivernomore):delete() -- SPENT 2HRS TRYING TO USE NATIVES JUST TO FIND OUT THIS EXIST AHHHHHHHHHHHHHHHHHHHHHH (DELETE_ENTITY doesn't work)
PED.SET_PED_INTO_VEHICLE(PLAYER.PLAYER_PED_ID(), vehicle, -1)
elseif vehicle ~= 0 and Vehicle(vehicle):is_seat_free(-1) then
PED.SET_PED_INTO_VEHICLE(PLAYER.PLAYER_PED_ID(), vehicle, -1)
VEHICLE.SET_VEHICLE_UNDRIVEABLE(vehicle, 0)
VEHICLE.SET_VEHICLE_ENGINE_ON(vehicle, 1, 1, 0)
else
notify.info("TinkerScript - Joyrider", "No vehicles in radius ("..jr_radius.."m) detected.\nIncrease your Teleport Radius.", 3000)
end
end
local DuffelBagSavePatch = {}
commandmgr.add_bool_command("DuffelBagSave", "Enable Duffel Bag Save", "Bypasses Duffel Bag save restrictions at Clothing Stores and Wardrobe.", false, function()
if not DuffelBagSavePatch.Shop then
DuffelBagSavePatch.Shop = ScriptPatch("clothes_shop_mp", "DuffelBagSavePatch1", "2C 0D ? ? 56 ? ? 72 2E 01 01 71 2E 01 01 2D 02 04", 7, {0x00})
end
if not DuffelBagSavePatch.Wardrobe then
DuffelBagSavePatch.Wardrobe = ScriptPatch("wardrobe_mp", "DuffelBagSavePatch2", "2C 0D ? ? 56 ? ? 72 2E 01 01 71 2E 01 01 2D 01 03", 7, {0x00})
end
DuffelBagSavePatch.Shop:enable()
DuffelBagSavePatch.Wardrobe:enable()
end, function()
if DuffelBagSavePatch.Shop then DuffelBagSavePatch.Shop:disable() end
if DuffelBagSavePatch.Wardrobe then DuffelBagSavePatch.Wardrobe:disable() end
end)
local OR_offsets = {
0x528, 0x568, 0x5A8, 0x5E8, 0x628,
0x668, 0x6A8, 0x6E8, 0x728, 0x768,
0x7A8, 0x7E8, 0x828, 0x868, 0x8A8,
0x8E8, 0x928, 0x968, 0x9A8, 0x9E8
}
local OR_ptr
local OR_selected = 0
local New_Name = ""
local renamemode = false
local canrename = false
local ibox_checkbox = false
local function ReNameEditor() -- deprecated
if not canrename then
if MISC.UPDATE_ONSCREEN_KEYBOARD() == 0 then
log.info(cls..lual.."Waiting for \"New Name\""..cls)
MISC.DISPLAY_ONSCREEN_KEYBOARD(0, "CELL_7000", "", New_Name, nil, nil, nil, 64)
canrename = true
elseif MISC.UPDATE_ONSCREEN_KEYBOARD() ~= 0 then
notify.info("TinkerScript - Re-Name Editor", "Open an \"Input Box\" first.", 3000)
log.info(cls..lual.."Re-Name Editor: \27[33mOpen an \"Input Box\" first.\27[m"..cls.."\n") return
end
end
while canrename do
local nn = MISC.GET_ONSCREEN_KEYBOARD_RESULT()
if MISC.UPDATE_ONSCREEN_KEYBOARD() == 1 then
notify.success("TinkerScript - Re-Name Editor", "New name is:\n"..nn, 3000)
log.info(string.format("%s%s\27[ARe-Name Editor: \27[32mNew name is:\27[m%s %s%s", cls, lual, nn, cls, cls))
New_Name = ""
canrename = false
return
elseif MISC.UPDATE_ONSCREEN_KEYBOARD() == 2 then
notify.info("TinkerScript - Re-Name Editor", "Logic canceled.", 3000)
log.info(cls..lual.."\27[ARe-Name Editor: Logic canceled. \27[B\r "..cls)
canrename = false
return
end
script.yield(0)
end
end
local ReN_Style = {
{ tbLabel = "R* Logo", tStyle = "∑"},
{ tbLabel = "Wanted Star", tStyle = "~ws~"},
{ tbLabel = "R* Verified", tStyle = "¦"},
{ tbLabel = "Lock Icon", tStyle = "Ω"},
{ tbLabel = "R* Created", tStyle = "‹"},
{ tbLabel = "Blank Icon", tStyle = "›"},
{ tbLabel = "Bold", tStyle = "~h~"},
{ tbLabel = "Italic", tStyle = "~italic~"},
{ tbLabel = "New line", tStyle = "~n~"},
{ tbLabel = "Reset", tStyle = "~s~"}
}
local ReN_Color = {
{ bName = "##Rednnf", bTip = "Red", tColf = "~r~", bCol = {0.870, 0.196, 0.196, 1.0} },
{ bName = "##Yellownnf", bTip = "Yellow", tColf = "~y~", bCol = {0.933, 0.776, 0.313, 1.0} },
{ bName = "##Bluennf", bTip = "Blue", tColf = "~b~", bCol = {0.360, 0.705, 0.890, 1.0} },
{ bName = "##DarkBluennf", bTip = "Dark Blue", tColf = "~d~", bCol = {0.184, 0.361, 0.451, 1.0} },
{ bName = "##Orangennf", bTip = "Orange", tColf = "~o~", bCol = {0.992, 0.517, 0.333, 1.0} },
{ bName = "##Greennnf", bTip = "Green", tColf = "~g~", bCol = {0.443, 0.792, 0.443, 1.0} },
{ bName = "##Pinknnf", bTip = "Pink", tColf = "~q~", bCol = {0.886, 0.309, 0.502, 1.0} },
{ bName = "##Purplennf", bTip = "Purple", tColf = "~p~", bCol = {0.513, 0.396, 0.878, 1.0} },
{ bName = "##Whitennf", bTip = "White", tColf = "~w~", bCol = {1, 1, 1, 1.0} }, -- doing 1.0 makes the button transparent for some reason
{ bName = "##Greynnf", bTip = "Grey", tColf = "~c~", bCol = {0.545, 0.545, 0.545, 1.0} },
{ bName = "##DarkGreynnf", bTip = "Dark Grey", tColf = "~m~", bCol = {0.388, 0.388, 0.388, 1.0} },
{ bName = "##Blacknnf", bTip = "Black", tColf = "~u~", bCol = {0.0, 0.0, 0.0, 1.0} }
}
local ReN_selectedprop
-- local New_PropName = "" -- Replaced with original one
local ReN_Properties = {
{ renProperty = "Office", renPropStat = "MPX_GB_OFFICE_NAME", renPropStat2 = "MPX_GB_OFFICE_NAME2"},
{ renProperty = "Organization", renPropStat = "MPX_GB_GANG_NAME", renPropStat2 = "MPX_GB_GANG_NAME2"},
{ renProperty = "MC Clubhouse", renPropStat = "MPX_MC_CLBHOSE_NAME", renPropStat2 = "MPX_MC_CLBHOSE_NAME2"},
{ renProperty = "MC Club", renPropStat = "MPX_MC_GANG_NAME", renPropStat2 = "MPX_MC_GANG_NAME2"},
{ renProperty = "Yacht", renPropStat = "MPX_YACHT_NAME", renPropStat2 = "MPX_YACHT_NAME2"},
{ renProperty = "Nightclub", renPropStat = "MPX_NIGHTCLUB_NAME", renPropStat2 = "MPX_NIGHTCLUB_NAME2"},
{ renProperty = "Acid Lab", renPropStat = "MPX_ACID_LAB_NAME", renPropStat2 = "MPX_ACID_LAB_NAME2"},
{ renProperty = "Acid Lab Product", renPropStat = "MPX_ACIDLAB_PRODUCT_NAME", renPropStat2 = "MPX_ACIDLAB_PRODUCT_NAME2"},
{ renProperty = "Mansion Dog", renPropStat = "MPX_MANSION_DOG_NAME1", renPropStat2 = "MPX_MANSION_DOG_NAME2"},
{ renProperty = "Mansion Cat", renPropStat = "MPX_MANSION_CAT_NAME1", renPropStat2 = "MPX_MANSION_CAT_NAME2"}
}
local JBvJG = {
SoV = false,
Phoenix = false,
SoVLoop = 0,
PhoenixLoop = 0,
PhoenixReactToNoclip = false
}
local function RapidOxidation()
if PAD.IS_CONTROL_JUST_PRESSED(0, 183) then -- G Key
JBvJG.SoV = not JBvJG.SoV
end
if JBvJG.SoV then
if (MISC.GET_GAME_TIMER() - JBvJG.SoVLoop) > 2200 then
STREAMING.REQUEST_NAMED_PTFX_ASSET("core")
for _, i in ipairs {{0x796e, 0.7}, {0x3779, 0.3}, {0xcc4d, 0.3}, {0xdead, 0.3}, {0x49d9, 0.3}} do
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_petrol_fire", PLAYER.PLAYER_PED_ID(), 0, 0, 0.0, 90.0, -100.0, 90.0, i[1], i[2], 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
end
JBvJG.SoVLoop = MISC.GET_GAME_TIMER()
end
end
if PAD.IS_CONTROL_JUST_PRESSED(0, 29) then -- B Key
JBvJG.Phoenix = not JBvJG.Phoenix
--if not Phoenix then GRAPHICS.REMOVE_PARTICLE_FX_FROM_ENTITY(PLAYER.PLAYER_PED_ID()) end -- This works but the change is too abrupt, phoenix wings slowly fading away look cool anyway
end
if JBvJG.Phoenix then
if (MISC.GET_GAME_TIMER() - JBvJG.PhoenixLoop) > 6200 then
STREAMING.REQUEST_NAMED_PTFX_ASSET("core")
for _, i in ipairs{{-0.30, 0}, {-0.35, 10.0}, {-0.40, 20.0}, {-0.45, 30.0}} do
if JBvJG.PhoenixReactToNoclip then
if commandmgr.get_command("noclip"):get_value() then
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1] + 0.50, -0.15, 0.03, -25.0, i[2] - 28, 0, 0x60F2, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1] + 0.50, -0.15, 0.03, 205.0, i[2] - 28, 0, 0x60F2, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
else
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1] + 0.50, -0.15, 0.03, -25.0, i[2] + 50, 0, 0x60F2, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1] + 0.50, -0.15, 0.03, 205.0, i[2] + 50, 0, 0x60F2, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
end
else
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1], -0.15, 0.03, -25.0, i[2], 0, 0x2e28, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_NETWORKED_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("ent_sht_flame", PLAYER.PLAYER_PED_ID(), i[1], -0.15, 0.03, 205.0, i[2], 0, 0x2e28, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET()
end
end
JBvJG.PhoenixLoop = MISC.GET_GAME_TIMER()
end
end
end
commandmgr.add_looped_command("rapidoxidation", "Rapid Oxidation", "Johnny Blaze meets Jean Grey...\n\nPress [G] to become Ghost Rider.\nPress [B] to unleash The Phoenix!", function()
RapidOxidation()
end, function()
notify.success("TinkerScript - Rapid Oxidation", "Rapid Oxidation enabled\nPress [G] to become Ghost Rider.\nPress [B] to unleash The Phoenix!", 3000)
players.get_local():get_ped():set_invincible(true)
end, function()
notify.info("TinkerScript - Rapid Oxidation", "Rapid Oxidation disabled.", 3000)
players.get_local():get_ped():set_invincible(false)
end)
commandmgr.add_bool_command("phoenixnoclip", "Phoenix Wings react to No clip", "Folds or Spreads Phoenix Wings based on No Clip state.", false, function()
JBvJG.PhoenixReactToNoclip = true
end, function()
JBvJG.PhoenixReactToNoclip = false
end)
commandmgr.add_bool_command("noclip_onscreen", "No Clip State On-Screen", "Displays a small window when No Clip is enabled.", false, nil)
local NoClipWindowTop = false
menu.add_always_draw_imgui(function()
if commandmgr.get_command("noclip_onscreen"):get_value() and commandmgr.get_command("noclip"):get_value() then
if not NoClipWindowTop then ImGui.SetNextWindowPos(screenX / 2, screenY, 0, 0.5, 1.0) else ImGui.SetNextWindowPos(screenX / 2, 0, 0, 0.5, 0) end
ImGui.SetNextWindowSize(150, 70)
ImGui.PushStyleVar(ImGuiStyleVar.WindowTitleAlign, 0.5, 0.5)
ImGui.Begin("No Clip", nil, 2 + 4 + 32 + 256 + 512)
ImGui.SetCursorPosX((ImGui.GetWindowWidth() - ImGui.CalcTextSize("Enabled")) / 2)
ImGui.TextColored(0.0, 1.0, 0.0, 1.0, "Enabled")
ImGui.End()
ImGui.PopStyleVar()
end
end)
local playing_anim = false
commandmgr.add_looped_command("noclip_anim", "No Clip Animation", "Makes your character play a Flying Animation when No Clip is enabled.", function() -- From YimMenu (I just wanted to clone my character and ended up with this... and completely forgot about cloning my character lol). I have no idea of what I have done here (if good or bad), but it works.
if (commandmgr.get_command("noclip"):get_value() and ENTITY.GET_ENTITY_HEIGHT_ABOVE_GROUND(PLAYER.PLAYER_PED_ID()) > 3) and not PED.IS_PED_IN_ANY_VEHICLE(PLAYER.PLAYER_PED_ID(), false) then
if (STREAMING.HAS_ANIM_DICT_LOADED("skydive@freefall") and STREAMING.HAS_ANIM_DICT_LOADED("missfam5_yoga")) and not playing_anim then
TASK.CLEAR_PED_TASKS_IMMEDIATELY(PLAYER.PLAYER_PED_ID())
playing_anim = true
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 4, 1, -1, 1 + 1048576, 0, false, false, false)
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 4, 1, -1, 2 + 16 + 32 + 131072 + 1048576, 0, false, false, false)
else
STREAMING.REQUEST_ANIM_DICT("skydive@freefall")
STREAMING.REQUEST_ANIM_DICT("skydive@parachute@first_person")
STREAMING.REQUEST_ANIM_DICT("missfam5_yoga")
end
if playing_anim and PAD.IS_CONTROL_JUST_PRESSED(0, 150) then
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@freefall", "free_forward", 4.0, 1.0, -1, 1 + 64, 0, false, false, false)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 6.0)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 6.0)
end
if playing_anim and PAD.IS_CONTROL_JUST_PRESSED(0, 151) then
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@freefall", "free_back", 4.0, 1.0, -1, 1 + 64, 0, false, false, false)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 6.0)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 6.0)
end
if playing_anim and PAD.IS_CONTROL_JUST_PRESSED(0, 147) then
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@freefall", "free_left", 4.0, 1.0, -1, 1 + 64, 0, false, false, false)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 6.0)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 6.0)
end
if playing_anim and PAD.IS_CONTROL_JUST_PRESSED(0, 148) then
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@freefall", "free_right", 4.0, 1.0, -1, 1 + 64, 0, false, false, false)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 6.0)
TASK.STOP_ANIM_TASK(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 6.0)
end
if playing_anim and (PAD.IS_CONTROL_JUST_RELEASED(0, 150) or PAD.IS_CONTROL_JUST_RELEASED(0, 151) or PAD.IS_CONTROL_JUST_RELEASED(0, 147) or PAD.IS_CONTROL_JUST_RELEASED(0, 148)) or PAD.IS_DISABLED_CONTROL_PRESSED(0, 36) then
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "skydive@parachute@first_person", "chute_idle_alt_lookright", 4, 1, -1, 1 + 1048576, 0, false, false, false)
TASK.TASK_PLAY_ANIM(PLAYER.PLAYER_PED_ID(), "missfam5_yoga", "c8_to_start", 4, 1, -1, 2 + 16 + 32 + 131072 + 1048576, 0, false, false, false)
end
else
if playing_anim then
TASK.CLEAR_PED_TASKS(PLAYER.PLAYER_PED_ID())
playing_anim = false
end
end
end)
local PTFXt = {
{ 1, "Explosion"},
{ 2, "Electricity"},
{ 3, "Sparkles"},
{ 4, "Blink"},
{ 5, "Poof1"},
{ 6, "Poof2"},
}
local Particles = false
local function TransformFX()
if Particles then
if PTFX == 1 then
GRAPHICS.USE_PARTICLE_FX_ASSET("core");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("exp_grd_grenade_lod", PLAYER.PLAYER_PED_ID(), 0, 0, 0, 0, 0, 0, 0x2e28, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(100)
elseif PTFX == 2 then
GRAPHICS.USE_PARTICLE_FX_ASSET("scr_fm_mp_missioncreator");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("scr_mp_elec_dst", PLAYER.PLAYER_PED_ID(), 0, 0, 0, 0, 0, 0, 0x2e28, 5, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(100)
elseif PTFX == 3 then
GRAPHICS.USE_PARTICLE_FX_ASSET("proj_indep_firework_v2");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("scr_xmas_firework_sparkle_spawn", PLAYER.PLAYER_PED_ID(), 0, 0, 0, 0, 0, 0, 0x2e28, 15, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(100)
elseif PTFX == 4 then
GRAPHICS.USE_PARTICLE_FX_ASSET("scr_indep_fireworks");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("scr_indep_firework_trailburst_spawn", PLAYER.PLAYER_PED_ID(), 0, 0, 0, 0, 0, 0, 0x2e28, 10, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(100)
elseif PTFX == 5 then
GRAPHICS.USE_PARTICLE_FX_ASSET("scr_rcbarry2");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("scr_clown_appears", PLAYER.PLAYER_PED_ID(), 0.3, 0, 0, 0, 0, 0, 0x2e28, 1, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(300)
elseif PTFX == 6 then
GRAPHICS.USE_PARTICLE_FX_ASSET("scr_powerplay");GRAPHICS.START_PARTICLE_FX_NON_LOOPED_ON_PED_BONE("scr_powerplay_beast_appear", PLAYER.PLAYER_PED_ID(), 0.3, 0, 0, 0, 0, 0, 0x2e28, 1.3, 1, 1, 1);STREAMING.REMOVE_PTFX_ASSET();script.yield(300)
end
end
end
local function TinyPlayer()
if not PED.GET_PED_CONFIG_FLAG(PLAYER.PLAYER_PED_ID(), 223, 1) then
if PAD.IS_CONTROL_JUST_PRESSED(0, 73) then
TransformFX()
PED.SET_PED_CONFIG_FLAG(PLAYER.PLAYER_PED_ID(), 223, 1);STREAMING.REMOVE_PTFX_ASSET()
end
else
if PAD.IS_CONTROL_JUST_PRESSED(0, 73) then
TransformFX()
PED.SET_PED_CONFIG_FLAG(PLAYER.PLAYER_PED_ID(), 223, 0);STREAMING.REMOVE_PTFX_ASSET()
end
end
end
commandmgr.add_looped_command("tinyplayer", "TinyPlayer", "Become Ant-Man?", function()
TinyPlayer()
end, function()
for _, i in ipairs {"core", "scr_fm_mp_missioncreator", "proj_indep_firework_v2", "scr_indep_fireworks", "scr_rcbarry2", "scr_powerplay"} do
STREAMING.REQUEST_NAMED_PTFX_ASSET(i)
end
end, function()
for _, i in ipairs {"core", "scr_fm_mp_missioncreator", "proj_indep_firework_v2", "scr_indep_fireworks", "scr_rcbarry2", "scr_powerplay"} do
STREAMING.REMOVE_NAMED_PTFX_ASSET(i)
end
end)
commandmgr.add_bool_command("tinyp_ptfxtoggle", "Particles", "Enables Particle Effects", false, function()
Particles = true
end, function()
Particles = false
end)
commandmgr.add_list_command("tinyp_ptfxlist", "Particle effects", "", PTFXt, 1, nil)
commandmgr.add_bool_command("hiddenlocs", "Hidden Locations", "Teleport to Hidden/Random Locations.", false, nil)
local BoxWidth = 0.208
local BoxHeight = 0.492
local xPos = 0.8545
local yPos = 0.312
local MM_msg = [[
~y~ Welcome to
Kiddion's Modest Menu!~s~
This mod is offered free of charge
and wihout warranty!
For any help, please visit the
Modest Menu thread at
~HC_64~https://unknowncheats.me~s~ and
carefully read the FAQ and Known
Issues.
~r~This is for EDUCATIONAL AND
EVALUATION PURPOSES ONLY.
NO responsability is held or
accepted for misuse.
~h~Use at your own risk!~s~
]]
local function ModestMenu(msg, x, y)
HUD.SET_TEXT_SCALE(0.0, 0.375)
HUD.SET_TEXT_LEADING(3.0)
HUD.BEGIN_TEXT_COMMAND_DISPLAY_TEXT("CELL_EMAIL_BCON")
for i = 1, #msg, 99 do
HUD.ADD_TEXT_COMPONENT_SUBSTRING_PLAYER_NAME(string.sub(msg, i, i + 98))
end
HUD.END_TEXT_COMMAND_DISPLAY_TEXT(x, y, 0)
GRAPHICS.REQUEST_STREAMED_TEXTURE_DICT("shared", true)
end
TS_Main:imgui(function() if not IsOnline() then ImGui.TextDisabled("Please join a freemode session.") return end
ImGui.BeginTabBar("MainCatTab")
if ImGui.BeginTabItem("General") then
if not windowcheck and ImGui.IsWindowHovered() then
nomoretreeplease = util.time()
windowcheck = true
elseif windowcheck then
if util.time() < nomoretreeplease + 5000 then
--ImGui.SetCursorPosX((ImGui.GetWindowWidth() - 300) * 0.5) ImGui.SetCursorPosY(5.0) -- not perfectly centered but I'll leave it here as an example of what not to do
CenteredText("Original TinkerScripts by ImagineNothing", true, false)
end
end
ImGui.Text("General")ImGui.Separator()ImGui.Spacing()
ImGui.BeginGroup()
commandmgr.get_command("fastrespawn"):draw()
commandmgr.get_command("fastreload"):draw()
commandmgr.get_command("infcombatroll"):draw()
commandmgr.get_command("ragdoll"):draw()
ImGui.EndGroup()
ImGui.SameLine() ImGui.BeginGroup()
commandmgr.get_command("notm25_bst"):draw()
ImGui.SameLine()
commandmgr.get_command("noidlecam"):draw()
commandmgr.get_command("m25_runboost"):draw()
if commandmgr.get_command("m25_runboost"):get_value() then
ImGui.PushItemWidth(80)
ImGui.SameLine() m25_yogaRmulti = ImGui.SliderFloat("Run Mult.", m25_yogaRmulti, 1.15, 3.0)
ImGui.SameLine() m25_yogaSmulti = ImGui.SliderFloat("Swim Mult.", m25_yogaSmulti, 2.0, 3.0)
ImGui.PopItemWidth()
tunables.set_float(-1585694365, m25_yogaRmulti)
tunables.set_float(-1986470272, m25_yogaSmulti)
end
commandmgr.get_command("m25_strengthboost"):draw()
commandmgr.get_command("clearworld"):draw()
ImGui.EndGroup()
if ImGui.Button("Force Cloud Save") then
STATS.STAT_SAVE(0, 0, 3, 0)
end
if ImGui.Button("Teleport into Personal Vehicle") then
ScriptGlobal(2640101 + 8):set_int(1)
end
if ImGui.Button("Teleport into Closest Vehicle") then
Joyrider(jr_radius)
end
ImGui.SameLine()
ImGui.SetNextItemWidth(100)
jr_radius = ImGui.InputInt("Teleport Radius", jr_radius)
ImGui.Spacing()ImGui.Spacing()
ImGui.Text("Auto-Drive") if ImGui.IsItemHovered() then ImGui.SetTooltip("Enables KnoWay Autonomous Vehicles System.") end ImGui.Separator()ImGui.Spacing()
ImGui.SetNextItemWidth(130)
VehAutoDrive.Mode, drivemodechanged = ImGui.Combo("Driving Style", VehAutoDrive.Mode, VehAutoDrive.Label, 3) -- I'll stick to add_list_command next time
ImGui.SameLine()
ImGui.SetNextItemWidth(100)
AutoDriveSpeed = ImGui.InputInt("Speed##wander", AutoDriveSpeed)
if ImGui.Button("Auto-Drive to Waypoint") then
script.run_in_callback(SelfTaxi)
end
if ImGui.Button("Auto-Wander") then
script.run_in_callback(Wander)
end
ImGui.Spacing()ImGui.Spacing()
ImGui.Text("Re-Name Editor")ImGui.Separator()ImGui.Spacing()
if OR_ptr == nil then
OR_ptr = memory.scan_pattern("40 5D ? ? ? ? 00 00 90 5D ? ? ? ? 00 00 00 00 00 00 00 00 00 00 00"):deref()
end
ImGui.AlignTextToFramePadding()
if renamemode then ImGui.Text("Mode: Business Renamer") else ImGui.Text("Mode: Outfit Renamer") end
ImGui.SameLine()
if ImGui.Button("Switch Mode") then
renamemode = not renamemode
New_Name = ""
end ImGui.Spacing()
if renamemode then
if ImGui.BeginListBox("##renprops"..nomoretreeplease, 400, 232) then -- https://www.unknowncheats.me/forum/call-of-duty-modern-warfare-ii/571696-imgui-listbox.html
for i, item in ipairs(ReN_Properties) do
local is_selected = (selected_prop == i)
if ImGui.Selectable(item.renProperty..": "..stats.get_string(item.renPropStat)..stats.get_string(item.renPropStat2), is_selected) and selected_prop ~= i then
selected_prop = i
New_Name = stats.get_string(item.renPropStat) .. stats.get_string(item.renPropStat2)
ReN_selectedprop = item
end
end
ImGui.EndListBox()
ImGui.SetNextItemWidth(400)
New_Name = ImGui.InputTextWithHint("##newrename", "New Organization/Acid Lab/Pet Name", New_Name)
ImGui.SameLine()
if ImGui.Button("Re-Name") then
stats.set_string(ReN_selectedprop.renPropStat, New_Name:sub(1, 10))
stats.set_string(ReN_selectedprop.renPropStat2, New_Name:sub(11, 20))
end
end
ImGui.SameLine() ibox_checkbox = ImGui.Checkbox("Input Box Override", ibox_checkbox)
if ibox_checkbox then
ImGui.SetNextItemWidth(400)
New_Name = ImGui.InputTextWithHint("##iboxoverride", "New Input Box Text", New_Name)
ImGui.SameLine() if ImGui.Button("Override") then
script.run_in_callback(ReNameEditor)
end if ImGui.IsItemHovered() then ImGui.SetTooltip("R* fixed input box filters. Consider this DEPRECATED.") end
end
else
if ImGui.BeginListBox("##outfitslots"..nomoretreeplease, 400, 232) then
for i = 1, 20 do
local outfitname = OR_ptr:add(OR_offsets[i]):get_string()
local is_selected = (OR_selected == i)
if ImGui.Selectable(i..". "..outfitname, is_selected) and OR_selected ~= i then
OR_selected = i
New_Name = outfitname
end
end
ImGui.EndListBox()
end
ImGui.SetNextItemWidth(400)
New_Name = ImGui.InputTextWithHint("##outfitname", "~ws~~r~¦~s~New Name~r~¦~ws~", New_Name)
ImGui.SameLine()
if ImGui.Button("Apply##OR") then
if New_Name ~= "" and OR_selected > 0 then
OR_ptr:add(OR_offsets[OR_selected]):set_string(New_Name:sub(1, 31))
notify.success("Outfit Renamer", "Slot " .. (OR_selected) .. " renamed!", 3000)
New_Name = ""
elseif (New_Name ~= "" or New_Name == "") and OR_selected <= 0 then
notify.error("TinkerScript - Re-Name", "Select something first!", 3000)
elseif New_Name == "" and OR_selected > 0 then
notify.error("TinkerScript - Re-Name", "Name is empty!\nPlease enter a name.", 3000)
end
end
ImGui.SameLine() if ImGui.Button("Copy") then
if OR_selected > 0 then
local copyoutfitname = OR_ptr:add(OR_offsets[OR_selected]):get_string()
ImGui.SetClipboardText(copyoutfitname)
notify.info("Outfit Renamer", "Copied: " .. copyoutfitname, 3000)
else
notify.error("TinkerScript - Re-Name", "Select something first!", 3000)
end
end
ImGui.SameLine() if ImGui.Button("Copy All") then
local AllOutfitNames = {}
for i = 1, 20 do
local outfitname = OR_ptr:add(OR_offsets[i]):get_string() or "(empty)"
table.insert(AllOutfitNames, i..". "..outfitname)
end
ImGui.SetClipboardText(table.concat(AllOutfitNames, "\n"))
notify.info("Outfit Renamer", "All outfit names copied to clipboard!", 3000)
end
end
ImGui.Spacing()ImGui.Spacing() ImGui.SameLine(0, 3.8) if ImGui.TreeNodeEx("Text Formatting ##"..nomoretreeplease, 8219) then
ImGui.BeginGroup()
for i, textformat in ipairs(ReN_Style) do
if i % 2 == 0 then ImGui.SameLine() end
if ImGui.Button(textformat.tbLabel, 100) then
if selected_prop ~= nil or OR_selected > 0 then
New_Name = New_Name .. textformat.tStyle
else
notify.error("TinkerScript - Re-Name", "Select something first!", 3000)
end
end if ImGui.IsItemHovered() then ImGui.SetTooltip(textformat.tStyle) end
end
ImGui.EndGroup()
ImGui.SameLine()
ImGui.BeginGroup() -- Table looks much better but this also work
ImGui.InputTextMultiline("##Colors & Symbols", [[
Use HTML/Hex if symbols don't work.
R* Logo: ∑ | ∑
R* Verified: ¦ | ¦
R* Created: ‹ | ‹
Lock Icon: Ω | Ω
Blank Icon: › | ›]], 280, 142, ImGuiInputTextFlags.ReadOnly)
ImGui.EndGroup()
ImGui.Spacing()
ImGui.BeginGroup()
ImGui.Text("Colors")
for i, textcolor in ipairs(ReN_Color) do
if (i - 1) % 4 ~= 0 then ImGui.SameLine() end
if ImGui.ColorButton(textcolor.bName, textcolor.bCol, 64) then
if selected_prop ~= nil or OR_selected > 0 then
New_Name = New_Name .. textcolor.tColf
else
notify.error("TinkerScript - Re-Name", "Select something first!", 3000)
end
end if ImGui.IsItemHovered() then ImGui.SetTooltip(textcolor.bTip..": "..textcolor.tColf) end
end
ImGui.EndGroup()
ImGui.Spacing()
end
ImGui.EndTabItem()
end
if ImGui.BeginTabItem("Misc") then
ImGui.Text("Misc")ImGui.Separator()ImGui.Spacing()
commandmgr.get_command("DuffelBagSave"):draw()
commandmgr.get_command("noclip_anim"):draw()
ImGui.SameLine()
commandmgr.get_command("noclip_onscreen"):draw()
if commandmgr.get_command("noclip_onscreen"):get_value() then ImGui.SameLine() NoClipWindowTop = ImGui.Checkbox("Top", NoClipWindowTop) end
commandmgr.get_command("rapidoxidation"):draw()
if commandmgr.get_command("rapidoxidation"):get_value() then
ImGui.SameLine() commandmgr.get_command("phoenixnoclip"):draw()
end
commandmgr.get_command("tinyplayer"):draw()
if commandmgr.get_command("tinyplayer"):get_value() then
ImGui.SameLine() commandmgr.get_command("tinyp_ptfxtoggle"):draw()
if commandmgr.get_command("tinyp_ptfxtoggle"):get_value() then
ImGui.SameLine() commandmgr.get_command("tinyp_ptfxlist"):draw()
end
end
PTFX = commandmgr.get_command("tinyp_ptfxlist"):get_value()
ImGui.SameLine(0, 200)
ImGui.PushStyleColor(ImGuiCol.Button, 0, 0, 0, 0)
ImGui.PushStyleColor(ImGuiCol.ButtonHovered, 0, 0.5, 1, 0.05)
ImGui.PushStyleColor(ImGuiCol.ButtonActive, 0, 0, 0, 0)
if ImGui.Button(" ##ModestMenuWelcomeMsg") then
script.run_in_callback(function()
for i = 1, 60*9 do
GRAPHICS.DRAW_RECT(xPos, yPos, BoxWidth, BoxHeight, 0, 0, 0, 200, 1)
GRAPHICS.DRAW_SPRITE("shared", "info_icon_32", 0.763, 0.090, 0.02, 0.036, 0.0, 255, 255, 255, 255, 0, 0)
ModestMenu(MM_msg, 0.756, 0.048)
script.yield(0)
end
end)
end if ImGui.IsItemHovered() then ImGui.SetTooltip("Triggers Nostalgia") end
ImGui.PopStyleColor()ImGui.PopStyleColor()ImGui.PopStyleColor()
commandmgr.get_command("hiddenlocs"):draw()
if commandmgr.get_command("hiddenlocs"):get_value() then
CurPlayerCoords()
ImGui.SetNextItemWidth(240)
ImGui.InputText("Current Coords", string.format("x: %.2f, y: %.2f, z: %.2f", PlaCoords.x, PlaCoords.y, PlaCoords.z), ImGuiInputTextFlags.ReadOnly)
ImGui.SameLine()
if ImGui.Button("Copy To Clipboard") then
ImGui.SetClipboardText(string.format("%.2f, %.2f, %.2f", PlaCoords.x, PlaCoords.y, PlaCoords.z))
notify.success("TinkerScript - Hidden Locations", "Current Coordinates copied to clipboard!", 3000)
end
if ImGui.BeginListBox("##hiddenlocsbox"..nomoretreeplease, 354, 232) then
for _, LocServ in ipairs(LocationCoords) do
if ImGui.Selectable(LocServ.LocName) then
PED.SET_PED_COORDS_KEEP_VEHICLE(PLAYER.PLAYER_PED_ID(), LocServ.LocCoords[1], LocServ.LocCoords[2], LocServ.LocCoords[3])
end if ImGui.IsItemHovered() then ImGui.SetTooltip(LocServ.LocDesc) end
end
ImGui.EndListBox()
end
end
ImGui.EndTabItem()
end
ImGui.EndTabBar()
end)
---|| Biz-Teroids ||------------------------------------------------------------------------------