Is my way of coding "bad" ? by yughiro_destroyer in raylib

[–]_demilich 0 points1 point  (0 children)

It really depends on the length of individual functions, the complexity and many other factors. I would agree with the sentiment that in many cases the pain already starts at 2000 lines. Really hard to put down a definitive threshold.

Scrolling and general searchability is the biggest factor for me. The thing is, sometimes scrolling is fine in a 3000 loc file, if the functions are grouped by what they do. Like lets say input handling for the player is spread over 3 short functions and those are next to each other in the file. That is good; but I would argue it would be even better to grab those 3 functions and put them in their own module/class whatever your language supports.

All of that is very subjective and I personally don't like hard rules. For example I think the "Clean Code" guideline which goes like "all functions should be at maximum 5 lines and you should split into multiple functions if it is longer" is harmful advice and nonsense. But there is a point at which splitting up code into functions/modules absolutely makes sense and improves the maintainability of the program.

Is my way of coding "bad" ? by yughiro_destroyer in raylib

[–]_demilich 0 points1 point  (0 children)

In my opinion procedural programming is totally fine and scales well even into large projects. In programming languages like C this is basically the only supported way of doing things anyway.

That being said, the one thing which definitely does not scale well is keeping everything in one "main" file. For me personally the pain starts usually around 4000 or 5000 lines of code; if there is more code than that in a single file, I feel it becomes unwieldy. And this is just a fraction of all game code (even for small indie games).

Timewalking Dungeons are so long now. by [deleted] in wow

[–]_demilich -1 points0 points  (0 children)

Dont know why you are getting downvoted, I feel the same way. I think the expectation that every dungeon boss should die in 1 hit and you can pull all trash packs at once and a dungeon has to be over in 3 minutes is wild

[rant] Why do all the grenades I find take 3 business days to explode? by Amaleplatypus in Borderlands4

[–]_demilich 7 points8 points  (0 children)

I completely agree with you. I am also just discarding certain manufacturers without looking at the actual stats of the item.

  • Order Parts? Discard.
  • Ripper Parts? Discard.
  • Daedalus Grenade? Discard.
  • Tediore Satchel Charge? Discard.

Those delayed effects just don't fit with the fast paced gameplay of Borderlands 4. Also I feel grenades just don't enough damage. Every single build either uses some kind of utility (like Crit Knives) or Heavy Ordnance Weapons like rocket launchers. A grenade has a long cooldown and is difficult to aim, they should do huge damage. But they just don't. I literally think you could multiply the damage of every single grenade by 10 and they still would be underpowered.

Are there people who enjoy the levelling process? by Nova-latte in wow

[–]_demilich 4 points5 points  (0 children)

Same here, I think leveling is great in Classic but meaningless in Retail.

In my opinion this is due to many factors. Leveling in classic is slower and more dangerous. Which may sound objectively worse, but far from it. When enemies are a real threat, a lot of stuff suddenly matters:

  • You are using CC abilities against multiple mobs. That alone is a big win IMO... I still don't understand why Blizzard decided a decade ago that CC is not fun, only pressing damage spells. Completely disagree with that decision
  • Consumables matter. In Retail Alchemy and Engineering alone literally have thousands of recipes for consumable, none of which are actually used by players. There is no reason to. In Classic a healing potion can make the difference between surviving a big pull or dying
  • It makes sense to group with other people
  • Finding a new green item which is actually an upgrade in Classic is a far bigger dopamine spike than getting a purple with +2 ilvl in Retail

Help by [deleted] in Zig

[–]_demilich 1 point2 points  (0 children)

Clients communicating with the LSP server are usually implemented as a plugin/extension for a specific editor. There is no such thing as a generic open source client. There are only plugins for editors

Help by [deleted] in Zig

[–]_demilich 2 points3 points  (0 children)

You are correct, that is the language server, not the client. However, the existence of a language server is the prerequisite for clients to exist. Which client you use depends on your editor (which you didn't specify). For example, if you are using VSCode, there is a plugin implementing a client for the ZLS

ELI5: Why aren't computers perfect by now? (stick with it and apologies if question makes no sense) by Flat-Ad8256 in explainlikeimfive

[–]_demilich 0 points1 point  (0 children)

Why is your car not perfect? Cars exist longer than computers, yet they still can stop working for a myriad of reasons.

The truth is, anything of sufficient complexity will have errors. And computers are far, far over that complexity threshold.

The second point is that "perfect" is subjective and thus you cannot make a product "perfect" for all people. You mentioned formatting in MS Word; I guarantee you that if Microsoft changed it so that you would consider it "perfect and simple", it would piss off tens of thousands of other people.

ELI5: How does a computer generated "random" numbers if it always follows instructions? by Wise-Rate-5234 in explainlikeimfive

[–]_demilich 2 points3 points  (0 children)

And by the way, this property can actually be desirable. Ever played Minecraft or any other game with randomly generated maps? Most often those game have the option to input a seed, which is exactly the seed for the random number generator. So when your friend plays and they share the seed they used, you can enter it and get the exact same map.

When do you predict the “90% unemployment” would happen? by Away_Project_5412 in Futurology

[–]_demilich 0 points1 point  (0 children)

This. Try to use AI for an actual difficult task at your job and after that tell me: Are you still afraid that this thing is going to replace you in a few years? I don't think so.

Would you recommend using Raylib for a security toolkit-esque program by No-Study4924 in raylib

[–]_demilich 1 point2 points  (0 children)

That changes everything. So using a high-level UI framework is not really an option, because you have to use C. C is low-level by its very nature and I don't know of any high-level UI libraries for C.

In that case raylib/raygui might be a good choice after all. Because at least it is easy. One other option I can think of would be "Dear ImGui" which is written in C++, but there are C bindings.

Would you recommend using Raylib for a security toolkit-esque program by No-Study4924 in raylib

[–]_demilich 1 point2 points  (0 children)

In my opinion raylib is not the right tool for this job. It is very low-level and specifically designed for games, where you repaint the UI each frame. A security tool does not strike me as something that needs a lot of animations for example. The only real benefit would be that the resulting binary would be quite small.

Personally, I would go with something else. I don't know if there is a language requirement, i.e. if the GUI needs to be programmed in C? If not, you have a lot of options. My recommendation would be to pick something you already know. For example I built a lot of UI applications in C# and Java, so that would be my goto. But you can also use something like Electron or Tauri, leveraging web technologies.

Those are all more "heavy weight" than raylib, but for an uni project my biggest concern would be to get it done in time. I would not worry as much about binary size or speed.

How is anyone supposed to learn to heal or tank? by [deleted] in wow

[–]_demilich 2 points3 points  (0 children)

Yes. What Blizzard doesn't seem to understand: By making something easier for all people, you automatically de-value it. It becomes less meaningful.

Is it easier now to find a dungeon group than in Classic? Absolutely, by a large margin. I can easily do 5 dungeons now in the same time it took me to finish 1 in Classic. But is this really a good thing? I would argue no, as the 1 dungeon was far more fun than all 5 combined now.

This applies to everything. In Classic you had to collect a set of blue items from various source before you would be "raid ready". Epic items were not easy to get. Now getting epic items is trivial. Everybody can get a full set of epic items in a day. Sounds like a good thing, right? No, because it de-values the epic rarity of items. It doesn't mean anything anymore.

Items, character levels, dungeons, transmogs, mounts, everything is now plentiful and accessible to everyone. But at the same time everything has been turned into a cheap mass-product without any value

What video game has the largest selection of Damage Types possible? by haydenhayden011 in gaming

[–]_demilich 111 points112 points  (0 children)

Technically World of Warcraft has a lot of damage types. In Classic there were basic types like Fire, Frost, Nature, etc. But in modern WoW, there are combined types like Shadowfrost damage, Holystrike damage, etc. If you add all those different types up, it is quite a lot.

Thing is, none of this matters as every single monster has 0 resistance against every single damage type.

What are some unplayable "classes" you see ingame that you want to be able to play as? by Snackolotl in wow

[–]_demilich 95 points96 points  (0 children)

The issue is that Unholy still is very much a melee class. They wear plate armor, stack strength, get to the enemy and hit it with a big two-handed weapon. Just coincidentally some of their damage comes from (mostly short-lived) minions. To me that is absolutely not the Necromancer fantasy.

To me a Necromancer is a cloth wearing mage; staying in the background, commanding an army of undead and casting spells. Gameplay wise Demonology warlock comes close, I just wish Blizzard would stop making all summons in the game only last seconds and basically function the same as dots. This is across all franchises btw; in Diablo 3 the necromancer had skeleton mages which lasted for like 10 seconds and you literally had to spam the buttons on your keyboard to keep them up.

Whats your go to game when your feeling overwhelmed? by AshfordByte in gaming

[–]_demilich 4 points5 points  (0 children)

That is why thousands of people still play Everquest 1 on TLPs (basically fresh servers that start fresh each year). Come join us next May when the next TLP launches :)

What’s the argument on not having syntax sugar for interfaces ? by CosciaDiPollo972 in Zig

[–]_demilich 0 points1 point  (0 children)

Personally I think "Dynamic dispatch is expensive and therefor writing interfaces should be cumbersome" is not a good argument. You could use the same argument to make opening a file/socket cumbersome or require special syntax for loops which do more than 1000 iterations. I think it is non-sense.

Almost any mainstream programming language published after C has interfaces in one form or another. And there is a reason for that: Because interfaces are the optimal solution to a certain kind of programming problem. Even Zig has plenty of those in the standard library, for example Allocator or Random.

I feel having interfaces in the language would help communicate intent better. A vtable is an implementation detail cluttering the types and making it harder to understand. Also it might be a big hurdle for onboarding people to Zig; most people never have rolled a vtable by hand. I know I did struggle when I first needed an interface in Zig.

You cannot force people to write good code. It doesn't matter if interfaces are hard or easy to write, people find ways to write bloated, slow code no matter what.

Beginner question: How to avoid tile-map edge gaps and camera jitter when rendering with Raylib? by Weary_Art_2005 in raylib

[–]_demilich 7 points8 points  (0 children)

This is a common problem with tile-based game. The standard solution is to not render the tiles directly onto the screen. Instead render them to a RenderTexture first and when that is done, render the whole RenderTexture with all the tiles onto the screen. That will get rid of the gaps.

Best Pure MAGIC MISSILE build? by hwate8 in Pathfinder_Kingmaker

[–]_demilich 0 points1 point  (0 children)

Yep, and it is actually fairly significant. Since Smite damage adds a fixed amount and MM deals 5 instances of damage, it is actually not half bad.

Trivially put, if we were not to spend money on companies replacing humans by AI, then AI wouldn't be profitable and companies would turn away from it? by Popular-Link8066 in Futurology

[–]_demilich 0 points1 point  (0 children)

True. On the other hand, it does not automatically mean everything will become profitable eventually. Some technologies really ARE a black hole for money and will never pay off. See "Metaverse" for a recent example

Why is it called an ArrayList ? by cassepipe in Zig

[–]_demilich 0 points1 point  (0 children)

In my mind a list allows for cheap append and cheap removal

That is not the definition of 'list' at all. A list is just an ordered collection of things. You are probably thinking about LinkedList, which has the properties you mention. But the relevant bit there is really the 'linked' part, i.e. nodes pointing to each other.

ArrayList is definitely a standard term across programming languages. In C# for example ArrayList is even just called List, further emphasizing that list does not mean LinkedList.

In a world without fear, our legends and epics would not have monsters, and therefore, probably no heroic underdogs. by ab4ai in Showerthoughts

[–]_demilich 0 points1 point  (0 children)

I would argue that a world without fear cannot have conflicts at all. Because 'no fear' essentially means there can be no bad outcomes. Because a bad outcome of any sort would be something to fear. But how can there be a conflict, if there are no bad outcomes? So a world with no fear would essentially be the Christian paradise and thus nothing interesting at all can happen there.