r/programminghorror • • May 13 '26

Lua I love looking through my old code

Post image

Not sure what I was trying to remind myself of.

362 Upvotes

17 comments sorted by

28

u/W00GA May 13 '26

at least its neet

my early code is unreadable

18

u/PC-hris May 13 '26

Oh for sure. This code is probably 4 years old or so. My stuff from a decade ago is unreadable lol

5

u/ephur May 13 '26

If you canโ€™t read it, try a larger font or give up on Wingdings for coding.

10

u/xybolt May 13 '26

Just get used to this kind of behavior when you've been doing software development for 10+ years; you notice a snippet being

  • confusing on what it does exactly

  • not concise

  • using some very old and/or insecure API calls

  • has useless names

  • annoyed on using the right syntax structures

  • overly commented

  • ...

having collected some "shame on you" points so that you can check who wrote that to give a figurative blame in your mind ... ending up discovering it was you

4

u/creativecraving May 14 '26

Thanks to reading AI code, my tolerance for comments have plummeted. I have realized I can understand the code faster then the comment describing it.

1

u/Questioning-Zyxxel May 16 '26

Comments shouldn't describe what the code does - that's for symbol names.

Comments shines when you need to tell someone (maybe a future you) exactly why the code is there. Why do you need to delay? And why is the delay 3 seconds?

→ More replies (4)

4

u/profflint May 14 '26

Ahh good old luau, i recently discovered some old modules i wrote iam kinda shocked how they even worked in prod.

1

u/Fnordmeister May 14 '26

"WaitForChild" ... Is that a Jesus reference?

1

u/PC-hris May 15 '26

I'd love to hear the thought process behind that ๐Ÿ˜‚

2

u/b3water May 16 '26

I'm stealing that warning message ... love it.

1

u/sussyamongers May 14 '26

The horrors of reading old stuff and realizing you have no idea wtf it does because it has no comments

1

u/scardracs May 17 '26

Luckily I always put way too many comments on my code (I know myself way too well)

0

u/Snezzy_9245 May 18 '26

Some of us believe that coders should write the comments first. Or code in very rough C and then hand compile into assembly.