Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Gamedev is really a special case (if we consider Web Development to be the "common case"). The fact is, when a company open sources one of it's projects, it expects to "benefit" from open source, i.e. taking community contributions, and make these contributions into its other closed-source products to generate profits. GPL forbids this, and naturally most companies open sources with MIT/BSD. And follows a repository on GitHub, many issues and PRs, CI, periodic releases (feel free to replace "GitHub" with "GitLab" or some server on some university, replace issues with mailing lists etc.) - that's what we typically expect from an "open source project" backed by other companies, in some other industries (most notably web development).

It doesn't work this way in games (at least for now), EA is only releasing part of the code for modding purpose, EA doesn't expect an "open source community" established on this codebase, and I also don't think EA has the intention to take contributions directly from community (by "directly" I mean, in code). If you have something you don't like about the game, post a comment in Steam and if you are lucky the devs are going to fix it themselves. It has always been working in this way in games, and it's not changing despite the "open source" action. So in this case, GPL is actually more helpful for EA, as illustrated by other replies.

But what I really want to say is, being a C&C modder myself (I've been modding RA2/YR from 2009 and also briefly worked on C&C3 later), I wholeheartedly support EA's decision to use GPL. Not because it's good for EA, not because I'm also a fan of RMS, it's because of the specific situation of the modding community.

If we take a simplistic view of a mod, it's roughly composed of "assets" and "code" (the same could be said for full games but it'll be more complicated). For assets, there are awesome free content creation software such as Blender and Krita, and tons of learning resources on the Internet. One can easily become a quasi-professional artist given enough exercise (I, personally, have undergone such a process). Well there is also things like music, but they all work the same way in which you "just create something in some external application (which is usually very powerful and extendable) and throw it in the game". You are not really limited in terms of asset.

The real problem is in "code" - modders are ultimately constrained by a proprietary engine, which heavily limits the possibility of mods. Just think about it: when you're making a real game, you can think about "What is the most interesting stuff I can come up with?" and then implemented it in the game engine. But when making a mod, whenever a fancy idea pops up, you're obligated to consider "Can it be implemented in the engine?". Unfortunately, most of the time, the answer is no. And this goes on and on, till a point where your imagination is imprisoned by the capability of the engine, that you lost the inspiration to design anything novel.

Why the engine is so limited? I think we can just imagine the scenario: in the crunch of getting the game finished, the devs don't really care about moddability, they just want to get it working ASAP, then they do all kinds of hack all the way along. In the end the game works, but modding it sucks. They hardcoded many stuff directly into the game engine binary, which is perfectly reflected by this set of search result: https://www.google.com/search?q=hardcode+site%3Amodenc.reneg... ... Oh and this is only about modifying existing stuff, we haven't started talking about adding a completely new system yet ...

To overcome these limitations, modders did a tremendous amount of efforts over the years:

There are attempts to reverse engineer the binary and patch it for workarounds: https://modenc.renegadeprojects.com/RockPatch

Then this approach evolved, they analyzed the binary to get the class hierarchy of the game, then use C++ to write new logic, inject the compiled routines into the binary: https://ares.strategy-x.com

There are attempts to rebuild the complete source code of the engine by incremental reverse-engineering: https://github.com/TheAssemblyArmada/Thyme

There are attempts to rewrite the whole game: https://github.com/OpenRA/OpenRA https://github.com/OpenSAGE/OpenSAGE



Continuing the parent ...

It seems I digressed a lot, but while one can make very sophisticated models, the "upper limit" of a mod, and the ceiling of the modding community as a whole, really lies on:

* How one can extend the engine. But this makes sense only if one can do this, i.e. has the skill, time, and resource to do it. It's not just some arbitrary CRUD logic, it's bulks of assembly code compiled from poorly written sources (thankfully the compiler is also poor so not much optimization).

* How one can make the best use of the existing features of the engine in absurd ways. For example, suppose I want a tank firing laser from the sky (think about Athena Cannon in Red Alert 3 https://www.youtube.com/watch?v=IbX7R3UYtzI), the engine doesn't offer such a feature. The solution is to set the Z component of the unit's "firing coordinate" to 65535 so it "looks like" firing from sky.

A more advanced example would be mimicing the sweeping laser of Colossus in Starcraft 2 (https://www.youtube.com/watch?v=u5YEI-_o5dQ), or laser of Future Tank/Giga Fortress in RA3. To do this, one can 1) Make a unit launch a V3 rocket, but make the rocket invisible; 2) Add a weapon to that unit, that automatically attacks the "rocket" it fires, make the weapon draws laser. Then as the "rocket" is approaching the target, the unit will attacking the rocket with laser, and as the rocket is moving, the laser will look to be sweeping. That's how you get this "BTS": https://www.moddb.com/mods/mklab/images/behind-the-scene

Surely this is a horrible hack and it'll break as soon as you have multiple Colossuses in a perimeter simultaneously - the laser weapon works by "filtering all rockets of a specific tag", but the tag can't be made specific to every "instance" of Colossus - there is just no such feature! They will just randomly pick a rocket fired by others and draw the laser and the whole stuff breaks up.

In reality, most people ends up in the later way because they can't do reverse engineering, there are many clever tricks just like the one above contrived by clever people. And even if you're working on the engine binary itself, it'll just be more difficult and time consuming to extract any non-trivial stuff from the huge sequence of instructions. All these won't be necessary if the game is open sourced. I personally feel sorry for all these brilliant minds "wasted" on these useless shits. And that's exactly why I don't do modding anymore (maybe I'll pick it up again if this open source of Remastered turns out to be interesting enough).

However, despite the grim situation, some people that's working on workarounding the engine just lock their stuff for themselves, for their own mods. They're not sharing. This means newcomers can't leverage their existing program databases to do new work, can't get their own features integrated with others, and even redoing much of others work (no source code access). As a result, fewer people want to get into this business.

This is not an accident: TibSun/RA2 uses their own ".mix" archive for storing assets and some of the code. It kinda like plain tar, just concatenate all files together w/o compression. But the format is designed to be read only by the game. It allows the archive to store only hashes of the filenames, the actually filenames can be omitted in the archive. When the game requests for a certain file it just use hash to identify the file. We have a GPL tool for working with these files. But to protect unapproved reuse of assets and modding of the mod itself, some modders intentionally omit the filename in archives of the mod they distributes to make it incomprehensible for other humans. They also tinkered with the file header so it's only readable by the game and not by other tools. This is, in fact, very reasonable, I'd say 60% people in the modding community are idiots, they're somewhat likely to just rip assets from other mods and use in their own mods without even crediting the original author. And sometimes it's just the author wants some "unique" stuff in his/her mod, and absolutely don't want others to use it under any term.

90% of the modding community don't know enough about free software, open source or GitHub (also reasonable since the modding community is just samples from ordinary players, and that's also why EA can't expect a proper "open source community"). They don't know how sharing stuff can make things much better. Of course it's their freedom to protect their work, and few people want to share stuff with idiots. I'm mostly with them for protecting assets. But as I said, the engine stuffs are different. These techs are critical for the future of the community, and are best shared as much as possible. I know someone who did some work on the engine, and has been treating these work as the most closely guarded secret since then, and even becomes paranoid. He once consulted me about "how to protect these magic from being exposed to the public with his mod". Well technically you can do it! (of course only to some degree) But what's the point of doing this?

That's why I think the GPL license mandated on the Remastered source can really make the community much more healthy. Though I'm not very confidence about it - I also discussed with the paranoid guy above about GPL long before the Remastered. I think one can easily infer that if one don't get the point of free software and open source, then he is also not likely to know GPL at all, even if he knows GPL he still can't get the point of it, and will hold the most utilitarianism view towards open source: If I can use it, then take it for myself and hide it deep inside my mod, if I can't use it, find some workaround to use it. After all, it's not likely that EA will sue a non-profit modder for a minor licence violation ...

Edit: Fix the typesetting




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: