Garry's Mod
TTT Randomat 2.0 for Custom Roles for TTT
161 件のコメント
Krimson 2024年12月23日 14時08分 
Thanks - I get no errors in sandbox anymore.
Malivil  [作成者] 2024年12月21日 18時38分 
Looks like I somehow missed that. Just uploaded a fixed version. Thanks!
Malivil  [作成者] 2024年12月21日 18時13分 
Hmm, it shouldn't load anything outside TTT. I'll see what's going on, thanks for letting me know.
Krimson 2024年12月21日 18時10分 
I get dozens of errors a second with this mod enabled whenever I enter sandbox mode. It's fine otherwise. And none of my other mods really give me errors at all. This is the error message I keep getting

[TTT Randomat 2.0 for Custom Roles for TTT] lua/randomat2/cl_events/cl_poltergeists.lua:20: attempt to call method 'IsSpec' (a nil value)
1. v - lua/randomat2/cl_events/cl_poltergeists.lua:20
2. unknown - lua/includes/modules/hook.lua:96
MutantBison, PhD 2024年4月7日 15時02分 
Ah okay, hard to keep track of which randomat mods add what, haha.

Thanks for the info, though! Will give it a try.
Malivil  [作成者] 2024年4月6日 18時10分 
That is not one of mine, but I think the fix is to go into the F1 settings menu and change the language dropdown there.
MutantBison, PhD 2024年4月6日 18時07分 
One of the randomats has permanently changed one of my friends UI to French. It's the one that adds the French flag and sound to the screen.

Not sure what's going on there.
Malivil  [作成者] 2024年3月23日 18時25分 
If the map has lots of props that's expected. It's moving every prop on the map multiple times
Cpt.Haxray 2024年3月23日 18時20分 
Server suffers massive lag with more than 8 players whenever the Fault Line Randomat triggers an Earthquake.
The Stig 2023年8月1日 4時30分 
Actually, my randomat mods do not require Custom Roles for TTT, but I will admit they haven't been as extensively tested as with it installed. I just played around with pack 1 now, and even the more complex randomat events from it were auto-triggering and working for me with no other mods installed.

All that should happen is the randomat events that require Custom Roles will simply be disabled, and others will trigger instead.
Enron2Big2Fail 2023年5月7日 12時11分 
Hmmmm, this is probably mostly teaching me I need to go through and sanitize my addon list.
Malivil  [作成者] 2023年5月7日 4時51分 
Though looking through your addon collections I see you actually don't have this Randomat at all, you only have one of Stig's (It should still work) AND you actually don't have Custom Roles for TTT at all which may be the core issue, since this and Stig's Randomats require it.
Malivil  [作成者] 2023年5月7日 4時48分 
Having trouble in what way? They aren't working?

The most likely cause is an error, so check your logs to see if something is happening.

If there is an error, it's mostly caused by a conflict with something else so make sure this is the ONLY Randomat version you have. Packs of events by people like The Stig, NoxxFlame, and Spaaz are OK but you shouldn't have other Randomats.
Enron2Big2Fail 2023年5月6日 17時34分 
I'm having trouble with the autorandomat trigger at round start (and the trigger random event button) any advice?
Tygron 2023年3月14日 12時59分 
Alright, i'll check that out ^_^
Malivil  [作成者] 2023年3月14日 4時45分 
Tygron: If you know how to use GitHub you can submit that event as as Pull Request and I can work with you to get it how you want it before merging in =)
Tygron 2023年3月13日 20時56分 
So I made my own Randomat event by modifying and combining a couple of the built in ones. It hasn't been properly play tested yet but we did it manually to come up with it. Basically take the harpoon event, change the harpoon to the newton launcher and spawn barrels around the player (because some maps don't have objects on them or if they do very few. So every 60 seconds much like Gunpowder Treason, barrels spawn. I have it set so that can be turned off though but eh.

I originally came here to ask how would I change the barrels to the regular non exploding type, because as far as I can tell the call for that is built into the Randomat itself and I didn't want to go changing that for a few reasons. I tried to take that code, change it, and make it work within the event but that was a no go. We just feel the idea is to smash the opponent not blow them up. But I mean feel free to steal the idea, we call it "Dodgeball" :P
Malivil  [作成者] 2023年2月3日 7時39分 
This one is specifically made for Custom Roles. I don't know how well it will work with vanilla TTT. You can try it and see, but I assume there will be a lot of errors.

There is a "Randomat 2.0" that this is based on that was for Town of Terror and that is based on the original "Randomat" which is for vanilla TTT. That will get you some events but it hasn't been updated in quite a while.
Bastianvvz 2023年2月3日 7時29分 
Hey Malivil, how are you? I have a question, I’m owner of TTT server, a long years ago i see events like this and i would like to add this to my server, but i dont have the roles addon (and i dont wanna add that, bc ppl is lazy to read…)
Can i add this addon to my server or its only to servers with custom roles?

Would appreciate your anws
Malivil  [作成者] 2022年8月13日 4時41分 
Nohbdy: Glad you got it sorted =) Also, I do have my own version of a ULX module that supports this version if you'd like to use it.
Nohbdy 2022年8月12日 20時24分 
Cool Got it working. I found an the normal version in my addons and also killed my ULX command mod for randomat and one of those two did it
Nohbdy 2022年8月12日 20時16分 
hmmm i know i uninstalled that i wonder iif its still in my addons folder. ill mess with it thanks
Malivil  [作成者] 2022年8月12日 18時25分 
Nohbdy: That probably means you have another version of the Randomat or Randomat 2.0 installed that needs to be removed.
Nohbdy 2022年8月12日 18時10分 
I'm Going insane. My Brute Force Tactics arent working. Please Help

[TTT Randomat 2.0 for Custom Roles for TTT] lua/randomat2/events/typeracer.lua:276: attempt to call method 'IsEventActive' (a nil value)
1. Condition - lua/randomat2/events/typeracer.lua:276
2. TriggerRandomEvent - lua/randomat2/randomat_base.lua:120
3. unknown - gamemodes/terrortown/entities/weapons/weapon_ttt_randomat.lua:100 (x5)

Thanks
Malivil  [作成者] 2022年4月22日 18時49分 
I tried to centralize the CR-specific logic but you would have to update the team checks and things like that.

There are also specific hooks that we added in CR for TTT that would either need to have their equivalent found in TTT2 or those events wouldn't work.

If you're willing to look into it, you can submit a pull request on GitHub (linked in the description) and I'd be happy to merge it in =)
SvveetMavis 2022年4月22日 16時49分 
curious on how hard this would be to port to ttt2, ive yet to look at the lua yet so no clue how simular it is
CATSNACKz 2022年1月26日 18時00分 
Awesome thank you!
Malivil  [作成者] 2022年1月25日 4時52分 
Ah, yes... I know why. Sorry about that, I'll fix it!
CATSNACKz 2022年1月24日 22時24分 
Timer Failed! [prep2begin][@gamemodes/terrortown/gamemode/init.lua (line 748)]

[TTT Randomat 2.0 for Custom Roles for TTT] lua/randomat2/randomat_base.lua:364: attempt to call method 'Enabled' (a boolean value)
1. CanEventRun - lua/randomat2/randomat_base.lua:364
2. GetRandomEvent - lua/randomat2/randomat_base.lua:447
3. TriggerRandomEvent - lua/randomat2/randomat_base.lua:471
4. unknown - lua/randomat2/randomat_base.lua:1038
5. unknown - lua/includes/modules/concommand.lua:54
CATSNACKz 2022年1月24日 22時23分 
randomat at start and trigger random event isnt working anymore. here's what looks like an error

[TTT Randomat 2.0 for Custom Roles for TTT] lua/randomat2/randomat_base.lua:364: attempt to call method 'Enabled' (a boolean value)
1. CanEventRun - lua/randomat2/randomat_base.lua:364
2. GetRandomEvent - lua/randomat2/randomat_base.lua:447
3. TriggerRandomEvent - lua/randomat2/randomat_base.lua:471
4. fn - lua/autorun/_randomat_loader.lua:62
5. RunHook - lua/ulib/shared/hook.lua:109
6. unknown - gamemodes/terrortown/gamemode/init.lua:1005
Malivil  [作成者] 2021年10月8日 15時26分 
Yes, The Stig and I work together to make sure his are compatible with mine
EnderSlayer366 2021年10月8日 15時20分 
Does this work with the 100 randomat mods?
MutantBison, PhD 2021年8月8日 15時00分 
Ah, I gotcha. I wasn't sure how a lot of those others were added or if they were just missing from this version. Thanks for the info and the links, Malivil!
Malivil  [作成者] 2021年8月8日 4時31分 
@LarryBoy101: That event was never in the base Randomat. You can get it either as a standalone, here: https://sp.zhabite.com/sharedfiles/filedetails/?id=2007014855
or in one of The Stig's Randomat packs, here: https://sp.zhabite.com/sharedfiles/filedetails/?id=2428342861
MutantBison, PhD 2021年8月7日 23時35分 
Does this version of the mod not have the randomat where every player gets converted to use the same skin? Because that was a fun one.
Malivil  [作成者] 2021年6月29日 6時52分 
I have updated the dependencies of this to point to the new Custom Roles for TTT because it is the new standard Custom Roles for TTT version.
The Stig 2021年5月26日 6時09分 
Tested and it works, thanks for that
Malivil  [作成者] 2021年5月26日 4時35分 
The Stig: That's a good point. It doesn't detect roles at all. For "Social Distancing", though, there is a delay before the damage kicks in so you sorta just have to dip in and then out and you're fine.

As for "Lonely Yogs", there is also a 2 second (configurable) delay so it will definitely be more difficult for a melee role but still doable (except for Vampires who won't be able to convert in time). I can add a check to not do Lonely Yogs if there's a Vampire just to be nice =)
The Stig 2021年5月25日 20時32分 
Does the "Lonely Yogs" and "Social Distancing" randomats detect if there is a melee role? i.e. a vampire, killer or zombie.

If not, would it be possible to add an option for those randomats to not trigger if someone is one of those roles?
Horolicht 2021年5月17日 0時43分 
@The Stig I will look into it :)
The Stig 2021年5月16日 23時22分 
@Horolicht Sorry if this comes off as too much of an advert for my own mod but I thought this might genuinely help you.

My randomat mod: https://sp.zhabite.com/sharedfiles/filedetails/?id=2428342861
adds a fixed version of the 'modelswap' randomat, it's called 'Who's Who?' (id: 'whoswho').
Try mine and Malivil's randomat mods together if you really miss that randomat event.
Horolicht 2021年5月16日 14時45分 
Yea I guessed it was because of the height changing events^^
Thanks again for all your work! You'll save me a lot of annoying swapping between models to get my original height back^^
Malivil  [作成者] 2021年5月16日 14時35分 
Ah, yea. You're right. The reason why mine causes this issue and others don't is I run the "event end" code for every event at the start of each round to fix a bug where some events weren't ending properly if the map changed while an event was still running.

The "Random Size" event from "MORE EVENTS" probably has the same problem because it also resets the ViewOffsets to the defaults in the "event end" code.
Horolicht 2021年5月16日 14時22分 
Actually the original Randomat 2.0 had not this kind of issue. Who knows why xD
Anyway I tested your change and it DOES INDEED FIX IT, so thank you for the quick fix^^

I just needed to unsubscribe to the TTT Randomat 2.0 MORE EVENTS (https://sp.zhabite.com/sharedfiles/filedetails/?id=2068742309) to make it work.
Don't worry I also tested your Randomat by itself, to make sure what causes problems.

Still I am a bit sad, that the MORE EVENTS Randomat isn't working properly. The modelswap event seems to be a ton of fun, but it's causing some error, no matter how I combine it with other addons.

Anyway thank you for all your dedication :Yonah:
Malivil  [作成者] 2021年5月16日 13時49分 
I just pushed a change that SHOULD fix it.

In addition to making sure it doesn't reset your view, please test the "Honey I shrunk the terrorists" event and make sure it still works for you
Malivil  [作成者] 2021年5月16日 13時25分 
I think all of them would have the same problem because the problem event was not one that I added =)

Working on the fix now though
Horolicht 2021年5月16日 13時20分 
Thank you soo much for all your input^^
I would be sad to use another randomat, since yours is by far the most optimized for the custom roles.
Malivil  [作成者] 2021年5月16日 12時58分 
I see why it's happening -- that addon sets the ViewOffset and ViewOffsetDucked of a player based on their model size. The "Honey, I shrunk the terrorists" uses the same properties to make players appear mini and it assumes that a player should be reset to the default offsets of "0".

I can make an update to save the previous offsets and use those values instead of the defaults. That should make it compatible again -- I'll work on that in a bit.
Horolicht 2021年5月16日 9時47分 
Hey I experienced some problem and perhaps you can do something about it.
The addon "Enhanced Camera" is not working properly because of the randomat. Means that the randomat seems to adjust the height of each player to the default height at the start of a new round. This takes away the height you originally had when playing with smaller/higher playermodels.
Swapping to a different model just to re-apply the playermodel I originally had solves the issue until the next round. Still can you perhaps look into the matter if you have time?
Malivil  [作成者] 2021年5月15日 4時17分 
Oh yea, that would do it... That addon replaces any active explosion effect with a new particle effect, completely ignoring any damage it would have done. I'm guessing it wasn't made for TTT.

Good find =)