I did some kewl coding over the last few days.
Networked Vars
I had a system in Lua where you could have networked values on specific entities. Meaning you set a value on the entity in serverside Lua and you can retrieve it in clientside Lua. It’s mainly used for display stuff, for example, the hoverballs float at a set altitude. We pass that altitude down to the clientside and draw effects based on how far away from its ideal altitude it is.
This worked well, but internally it was a mess. BaseEntity had 10 ints, floats, vectors and entities on it. Meaning that every entity was carrying a wad of shit around with it even though half of them probably weren’t using it.
So it was eating me up and Helk came up with the solution. Hook the usermessage shit up to Lua and then program a transport system in it. I did it, and it works. I expected it to take a lot more bandwidth, but it’s about the same. There’s no real obvious negative effects anyway.
The entities aren’t limited to x amount of networked variables now, so they can have unlimited networked vars. Plus you can index them by string (previously they were always indexed by int 0-9).
So it’s pretty cool. I hooked some functions to exchange global vars too, so you can be like SetGlobalString( “Title”, “Welcome To The Show!” ) then on the client draw on the HUD, draw.SimpleText( GetGlobalString( “Title” ), … ). Awesome!
Skippy Weapon Prediction
The sent’s were being all skippy. It was calling the weapon’s prediction multiple times with commands in the wrong order. I hacked around it by comparing the time of the command with the last one and returning if it was out of date. This was another thing that had me going “fuck.” – but it’s all good now.
GMDM
All this shit was discovered/fixed while working on GMod Deathmatch. The Lua gamemode I want to put out as a working example of how to make a gamemode (IE making it first and then worrying about weapon models, who is going to do PR and who’s heading up Human Resources). I’m basing it on HLDM, since I love HLDM.
The egon gun. Pretty much exactly the same as the one in hldm. Except with an awful elevator sound.
The tripmines are pretty much the same too, except you throw them instead of placing them. And they’re tea pots.
Nice, thats some pretty nifty stuff.
Nice one Garry, you’re progressing far with GMOD 10, I can’t wait to get my hands on the game huzzah!
Oh yeah i was also thinking you should put a direct link in the blog’s sidebar or something to the garrysmod images folder for easy access. gmod.garry.tv/img/garrysmod
Will the flamethrower you showed us for a while ago be in gmdm?
Nice nice nice… I am assuming these weapons will be spawnable in construct?
Cool.
good work garry! wow GMod 10 is making me salvate lol
Very nice, I love these Gore effects :D
SWEET! I loved the video with the tripmine, that blood effect is so cool…
Wow, actually looking crazy, i can’t wait!
Nice job
Any news on facewound?
Nice job
Any news on facewound?
That day Gmod 10 comes out, i get a heart attack!
Nice man! Are the Zombine NPC in GM10?
Awesome work . :)
Could you show us a piece of code from thoses weapons , Garry ? I’d like to have a look at it .
To Raven : normally , you can code SNPCs with Lua . So this means that the zombine would be possible to be scripted .
Teapots?
You, sir, are fucking genius.
Ahh the time of huge massive improvised cannister thrusters :D
heh I thought the ghosts where ment for halloween and that the ghosts where npc sprites. Darn I was hoping for game where you go out and capture ghosts that hide in shadows.
Tea pots :D
For a second I thought you said you love hl2dm and I’m like, wtf?! I like how the laser comes out where the tea comes out! =D
Absolutely kick-ass. I loved the Egon Gun in Half-Life 1. So…unopposed. I LOVE the blood and gibbing effects you’ve put in.
Gotta enjoy the “awsome” “nice work” “whoho” comments until it turns back into “update your blog” “RELEASE IT !!!!111one” and such again :D
Nice Work BTW :)
Great :D
I love this Babydolls and the screams xDD
But the egon gun reminds me somehow on a KameHameHa or on the Ghostbusters-Laser xD
I’m begining to think of what MingeBags can do in Gmod10… Ooohoho it’s not going to be pretty.
Luckily i’m not a MingeBag :D
I love those blood effects, and the elevator sound for the Egon gun isn’t THAT bad :S
It’s cool that you’re getting rid of bugs that we probably wouldn’t even care about.
WTF Garry. Why did you leave you Steam account name out in the open?
Garry you do realize that you are showing your Steam screen name at the right hand corner? You are going to get a lot of messages from a lot of friends while your online.
I was brought to tears (laughter) by the soul’s screaming. It really is awesome. And the Egon Gun really doesn’t sound bad, I could easily see you leaving the sound for the gun as is and no one would argue. It doesn’t sound like an elevator unless you actually go and think about it.
As for Wow, that is gonna be Gmod Deathmatch, while it would be easy for the server owner to port the guns over from the gamemode, if he/she were to leave it freely accessable to anyone, then it is essentially their own fault for making it possible for the minge to get the gun. The blood effects are sick. :D
hey did anyone notice they updated the source engine today
“hopefully in wake of gmod 10″
cant wait bty sweet gun my man sweet gun
omg, garry you are awsome, i cant wait for gmod 10, and to use a direct quote from fear “You are a god among men” explanes it all to wel.l
keep up the excelent work gmod team.
Now that’s an anti-minge wepon i could get used to. Hehe. I really can’t wait to blow up ll my friends with it. It shall be fun.
BTW bob the “update” was nothing more than this: Added Polish support for Source games
Not sure if that’s the language or actual polishing of stuff. We shall see I guess.
Your blowin my mind man, your blowin my mind! the ripple effect you added to the trip mines is awsome. The refraction shader is so cool.
Hahaha oh man, awesome. Does crossing the streams do anything for the Egon Gun? Oh please tell me something happens.
Erm, something does happen. You blow up. If that’s what you mean :P
ZeroCrash, I meant the normal Gmod10. They could make random objects motors, bind “Break” to a button (Toolgun button thingy with the clock) and assign it to random props, use the Hydroulics (If thats how you spell it :x) Toolmode to push into random objects, it would be terrible man.
OH NO you meant crossing the streams, like in Ghost Busters :D
I have no idea… I hope something does happen >:D
Look I made things neater.
The end.
Like what thedef?
Also those effects are friggin’ awesome!
Hey what if we use some enitiy grabbing tool then grab a trip mine, I wonder if it might crash and I hope Gmod 10 comes out soon.
You make me want this very badly ;)
…You bloody bastard
So true shaggy…
If this gamemode is as good as it looks from the screenshots we’re getting, you’re gonna put HLDM outta business. I mean, who would play with normal HL2 weapons when you’ve got all this fancy Lua stuff. Cmon, teapots!!
the light coming from the beam is so awesome
There is something very, VERY, wrong with this picture… I don’t have Gmod10! That’s it! Just kidding :D
Btw, about him showing his screen name, everyone knows what it is, he has posted it in many images before now.
o6 charger o ok
Garry, tell us, when will gmod 10 will be realised? You said that Steam team must to do some work on steam… What exatcly they mean? Could you say when we may buy it? In 2007? No, I realy want to know where Gmod10 will be available?
KEKC, it’s been said, OVER and OVER. Garry will NOT tell us when it will be released. The release date is ENTIRELY dependant on Steam and when they complete what it is they’re doing for GMod. Garry could release it early, but then he would make no money which would be crap.
I didn’t say they’d told me a release date. I said they’d told me a date for the work to be done. And that date has passed, and the work has been done.
Bad valve :(
The date has passed and the work has been done? So does that mean valve has gotten what you need in place now? That is what I assume but I may have misread that.
Sorry for the double post! I forgot to mention, that egon looked so freaking sweet, seriously. I am really impressed by that, makes me steeple my fingers and moohaha loudly =D.
i wonder why ppl love so much garry. Why you dont love Bill Gates? He made Windows and somehow it would be not possible to play such Games on Linux or MAC. It is possible but the arround working sucks much. He only modified some Game content that isnt a big job at all i know someone who could do this alot better but he dont want to because he thinks its useless todo something like this people would say: “You copied Garrys Mod” like the old mod i cant remember JibberMod or something
CiPH you like donkey cocks.
CiPH, realy – I hate windows! It’s laggy… I like more Mac, but steam doesn’t work on MAC :(
CiPH…
“He made Windows and somehow it would be not possible to play such Games on Linux or MAC.”
If windows didn’t exist, it would be very possible to play games in Linux just like now in Windows. Problem is, that devs don’t bother to make games to Linux because today almost everyone uses Windows. If majority of players moved to Linux, majority of games would be developed to it too.
Bill Gates is more of a marketing genius than a coder. Don’t get me wrong, he must be awesome at coding too, but it was his marketing skills that brought the victory over to Windows, rather than OS/2, which they had developed with IBM.
And true, if Windows wasn’t in such a monopoly position as it is and Linux or another OS would be in the ruling position, also the majority of games would definitely be released for that one OS.
Jesus, gareh! What is your resolution?
So umm what I got out of that is that steam will release when they want?