Garry's Mod

Garry's Mod

Combine APC
Zaubermuffin  [developer] 17 Feb, 2020 @ 2:18pm
The x64/Chromium Update and the Combine APC
Hello all,

this is going to be the official what's-going-to-happen thread regarding the Combine APC.

What IS going to happen?
Whenever the x64/Chromium/whateveritscalled update for GMod is released, the Combine APC will be removed from the workshop.

Why is the Combine APC removed from the workshop?
Changing the gears/speed setting on the APC is crashing the server. This is a new GMod issue that wasn't there before.

Can't you fix it?
I can't, and apparently neither can the GMod devs. There's certain workarounds that could work, but would either be significant work/not produce proper results (read: fit my standards).

Let's be technical: What's the issue?
The APC is one dense motherreproducer. As such, it has difficulties climbing some hills on some maps, which is why the second speed setting was added. The same setting also works quite nicely if you want to actually drive along some normal people walking, instead of annoyingly tap W all the time.

This is realised by having two vehicle scripts, one for normal operation and one for the slow drive. It's toggled with +attack2 by the driver, which is setting the jeep (the APC is basically just a jeep at its heart) to the other script, then reloads the scripts using vehicle_flushscript.

This worked fine from 2011 until about now. With the update, vehicle_flushscript is causing the server to crash. There's nothing I can do here except working around it, because apparently the issue is caused by Valve's vphysics.

There's SetVehicleParams now, but that does not allow setting certain things, like e.g. the sounds. It also means that I have to convert the vehicle scripts to lua tables/similar, and let's be honest, the API for that is somewhat stupid. The getter returns hammer units per second, but the setter expects miles per hours? What? This wouldn't be an issue for me (as I'd just set constant values anyway), but... I digress.

SetVehicleParams cannot do sounds, so I would either have the normal sounds even when it's going slow, or I would have to do some workaround (by hooking GM:EntityEmitSound for example). There's various problems with that:

  • There's a bloody good chance the gamemode or some other addon wants to call dibs on that, and as the hook can only be resolved by one listener, they would steal the chance for the APC to adjust the sound.
  • Vice-versa, it's possible that the APC can flip the sound and completely ignore what some addon/gamemode would like to do (like quieten some sounds or similar).
  • Using that system would require me to somehow have a logic when to replace what sound, and what to replace it with.

TL;DR. What's up?

  • The update causes some core functionality of the APC to crash servers.
  • There's no simple workaround.
  • It's apparently not fixable by GMod itself.
  • The complicated workaround would require a rather large code change and would not produce satisfying results.
  • The APC will be removed from the workshop as soon as the update hits.

Thank you for your understanding, and thank you for the support in the past almost decade!
< >
Showing 1-15 of 28 comments
Nitride 21 Apr, 2020 @ 11:32am 
F
Reed777 27 Apr, 2020 @ 4:14am 
F
Salty 0ct0pus 27 Apr, 2020 @ 11:38am 
F
Zaubermuffin  [developer] 29 Apr, 2020 @ 3:03am 
In order to prevent people from crashing after the update hits (because there's still around 200k subscribers at the moment...), I've pushed an update that disables the gear changing altogether. It's limited functionality now, but does not crash - it's not going to be public anymore, however.
Aspect™ 29 Apr, 2020 @ 7:02am 
Rip.
Couldn't you just remove the gear changing altogether? I think some people would prefer tapping w if they wish to move slowly rather than completely losing this addon.
Zaubermuffin  [developer] 29 Apr, 2020 @ 10:21am 
That's what I've done with the compatibility patch I've released today. However, it doesn't fit my requirements for a proper APC anymore, and it's not usable on a wide range of maps as a result.
Drako 30 Apr, 2020 @ 12:18am 
F
Fatty bruh moment, loved this addon since 2015, good 5 years, F
Snake343 19 May, 2020 @ 2:04pm 
F
Engi Man 21 Jun, 2020 @ 12:47am 
Please dont remove, we can play without crashing anyways
ra 26 Jun, 2020 @ 6:35am 
f
hilosonman 14 Jul, 2020 @ 2:25pm 
F
Mr.Bonk 1 Sep, 2020 @ 11:03pm 
F
Zer0n 22 Nov, 2020 @ 10:38pm 
F on singleplayer is working normal is that problem in multiplayer game?
< >
Showing 1-15 of 28 comments
Per page: 1530 50