Post your coding goofs

Ultimately it’s the finished product that matters, but every now and then everyone will run into a bug in their script or addon while developing. Sometimes it’s nothing more than an annoying error that keeps things from working properly but sometimes they can cause interesting results.

I’ll start:

This was one of my earliest attempts at making a custom tracer. It obviously didn’t come out of the muzzle of the gun like it was supposed to.

Making huntsman-like arrows…

And a nice compilation of NPC and weapon related mistakes

If you’ve got a misnamed variable or an extra zero or anything that causes something unintended, unexpected, and interesting post it here!

Surfing cyberdemon poops metal caged death:xd:


Oh god just saw the end:v:

I can’t stop laughing at the shitting out explosion at the end

[lua]function banPlayer(ply, target, time, reason) {

Felt dumb when I realized that Lua != Java




This makes me regret i didnt film my failed attempt with ragdoll AI

My fail attempt with ragdoll AI made 50 ragdolls spawn out of 1 NPC when he died.

Needless to say, lag ensued.

I probably have a couple screenshots of issues I had in the past, will upload when I get home

Unexpected, epic ending to the second video.

I haven’t got any pictures or videos, but when developing PCMod I managed to stop the world from drawing - which didn’t fix across map changes. And once in a zombie survival gamemode I was coding the chem zombie, except I accidently made an infinite loop and so when the chem zombie died - the explosion noise makes your ears bleed, kills any player nearby about 20 times over instantly and throws all props and ragdolls miles into the air. Just a tad overpowered.

For a while I couldn’t figure out what was wrong with one of my aircraft, before I realized I had put the weight variable into a different direction, so the aircraft were all falling sideways.

No particular order chronologically



don’t know if this next one counts - never leave Create Multiplayer on overnight


I somehow managed to stop ALL game rendering resulting in just a grid paper like screen.


Don’t remember what I did…

Happens when you fuck up with Jinto’s rendering module.


I was working on a script that automaticly ‘unstucks’ the player when it’s stuck in the world. I messed up my calculations and caused this rampage:


Here I messed up with setting the player position. This was one of the few weird things I’ve experienced in source. When you’re lightyears away from the map origin, everything looks crushed like a cardboard.



Messed up projecting a HTML panel…


Crush lady CRUSH


This isn’t really a fuckup, but I couldn’t resist to post it here.

I was trying to make a spam auto ban, but i managed to perma ban everyone on the server. That was great.

I didn’t know you had to set owner, the only way you could delete them was with the remover tool, server clean up wouldn’t even work


Oh and I was making a BillBoard type thing and I managed to get a Draw error which caused most of the world to not even render visually.

Oh my god… I laughed so hard at the first movie :smiley:

This isn’t exactly lua, but the biggest fail I’ve ever done with “code” is in expression two when I was only a couple months into it. I made a ragdoll float and “attack” you by lunging at you like a zombie, yet for some reason the version I posted online was flipped upside down, resulting in hillarity. No screens, but here’s the e2:

Oh WOW, I know that italian kid (I’m italian too :3)
Well, that guy “kerberos” is a 10 yr old kid named Luigi, and he is the perfect example of noobines… And he can’t even type italian right O.o

Just spent the last twenty minutes trying to figure out why, when I hooked into this function in my clientside Lua file, it didn’t call at all, and yet when I hooked in via console, it worked just fine.

Just found the answer to my problems a few moments ago:

[lua]function InfiniDungeon_PrePlayerDraw(ply)
– stuff

hook.Add(“PrePlayerDraw”,“InfiniDungeon - PrePlayerDraw”)[/lua]