Hi, Forgive me if this has been answered already, but I am a Programmer by trade, and have never delved into game mods before, but would like to have a little dabble when PA comes out. What language will mods be written in? I am talking about gameplay mods here, not any UI tweaks etc. Mike
If you are a professional programer then it should be trivially easy for you to learn whatever scripting language PA uses for mods and whatnot. I mean once you really know C/C++ its pretty easy to pick up any other language really. Knowing C/C++ is like knowing latin, you may not know any other languages, but you can kinda understand a surprising number of them anyway.
Unfortunately, i dont know C/C++ which is one of the reasons Ive never done any programming for games! Just wondered if it would be a more modern OOP language?
Well while PA itself is going to be written at least in part in C/C++ I imagine that the mods will be in a less powerful and more accessible interpreted scripting language. I think Mavor mentioned what language they were going to use in one of the live streams but I can't remember. I know that he said they were not going to use Lua like TA did. And C++ is perfectly capable of doing OOP. Its probably the best modern language around for general purpose programing. Even C# doesn't give you the kind of memory control that C/C++ does that is often needed for more demanding tasks. I took a few semesters of C/C++ in college and even though I have never done any serious work in C/C++ I am so glad that I know some of it. It has made learning every other language that I do know soooo much easier.
I'm currently in the process of learning Python (my first dabbling at programming in general) and then I plan to march into C/C++. I would like to be able to mod in PA if only for the practice. Then quantum computing... Finally, the world! :twisted: But well, one step at a time... Thoughts? (disregard the quantum computing bit, please! :lol: )
Do you know Java? Java shares a VERY similar syntax to C++, so you should be able to learn C++ fairly quickly if you know Java, though there are a lot of things that you should really be aware of to use C++ properly in a game, such as not allocating memory (using new) at run time and having a good handle on the life of objects (when they are allocated and when they are freed) so you won't be accidentally using an object that no longer exists, usually just creating objects in a specific order and destroying them in the reverse order takes care of that. Yeah I love C/C++, now that I'm proficient with it I rarely have any trouble just jumping in and using new languages, other than when the other languages are not able to do something I can with C++ at least . It's also very hard to compare the speed any other languages to the performance of C/C++, if you know what you are doing then there's very few languages as fast as it, the only real exception is maybe assembly, but since assembly code can be mixed in with C/C++ code with little effort there's no reason not to use C/C++ if you want the fastest code. C++ also has a huge amount of control over it's memory use which can be very important for games, I've always liked that in C++ data is just data, it doesn't matter what class is using the memory you can just grab the raw data and manipulate it however you want, that can lead to some pretty big problems if you mess something up but when you know what you are doing you can really do some incredible stuff that just isn't possible with many other languages. IMO the only issues with C++ is that once you know it well enough other languages can be a pain in the *** sometimes because you can't use all the little performance and memory saving tricks you know , and the standard C libraries are pretty bare bones, there's very little functionality (like GUI libraries) included with C/C++, though there are plenty of third party libraries available for that sort of thing . I've just done some of my first python coding and I've got to warn you that that will be a tougher road than from other languages, python doesn't have a lot of the syntactical elements like opening and closing braces that C++ and many other languages have so you'll probably end up with a lot of errors programming when you first start writing C++, when I was coding in python I kept adding them in by habit creating a heap of errors so you'll might experience the reverse and forget them which can be a real pain to track down in C++ sometimes, but at least you'll have good indentation which should make that much easier . Python was one of the trickier languages I've dealt with going from C++, still not much of an issue, but it was different enough that I would look at it and be only half sure it was syntactically correct whereas most other languages I would know at a glance that everything was in order. When you switch over to C++ be prepared to break quite a few habits you didn't know you had developed .
Best way to learn is to be like to Borg, and just assimilate other parts of code to do what you want. Why create when another part of code already does what you want else where?
Likely because the act of creation involves understand the material you're working with. Copy/pasting a chunk of code might work, but 9 times out of 10 if you re-wrote the module yourself you'd understand exactly what it's doing, and how it could be improved / modified to better fit your particular problem. It's like the difference between a 'new' unit in the game where someone just ripped some turrets off a battleship and slapped them on a scaled up tank chassis, and the design of the fatboy. They both may serve the same purpose, but one just looks and works better than the other.
Well compiled binaries generally don't convert back to source code all that well and then there this little thing called copyright law. Not everything is released under the GPL.
Ive programmed a tiny bit of Java back in my University days, but mainly do C# now, though I realise theyre not worlds apart. Ive programmed Objective-C for iOS too (before ARC and since ARC) and so I know the concepts of memory management too, though it proved a tricky thing to deal with, which is why ARC is great! Well, hopefully, I will be able to program mods in something which automatically manages memory, as it was an incredible bain when I was programming my 1st iOS app... I figure we will just have to watch this space re: the language used. Does anyone know if Uber plan to release any documentation to support modding? Mike
I can't imagine they'd give us a modding language which would allow us to create memory leaks as any bad mods would then reflect badly onto the reputation of the game itself. I believe they were planning on releasing information about modding around the last livestream, but it got delayed. So I'd guess it'll be released soon™.
Think you may have meant to post that in the other thread . Anyway generally if you want to use C++ for mod support you release an SDK with only the code for the modable part of the game, and there's usually a section in the EULA to cover the legalities of mods and the source code (typically any mod created belongs to the company that owns the game and the source code is restricted to use only for creating a mod), so it's not really too big an issue to use C++. However it does require a fair be of extra development making sure the SDK is up to date, documented properly, and designing the code to support such modding, which is why a lot of games do use scripting languages instead, they require a hell of a lot less maintenance and for a lot of games the performance issues in the modable section of the game isn't much of a concern anyway. Going from C# to C++ should be pretty much the same as from Java to C++ so you should be fine if Uber just use C++, though I suspect they will probably use a scripted language for at least part of the modding because as I said it's a fair bit easier to roll out and maintain a scripted language so it may not even be an issue . Managing memory is actually quite easy though, you just have to structure you code in certain ways and I find it's even easier than automatic memory management, the main trick to it is to have a well defined life for an object, and a rigid order of creation which is reversed for destruction, then as long as an object only uses objects created either before or by it then you never run into any major issues . Yeah, I think Mavor mentioned in the last live stream that they were going to release some more info on modding very soon so hopefully the wait isn't much longer . Not yet, and it could really go either way, they might want to get the tools out really quick and push it out with very little documentation initially, or because they have always known they would support modding they could already be diligently documenting stuff as they go in which case we'd have tons of documentation . I expect the modding community to be pretty good for PA (I remember the TA modding community was always very good) and so either way we'll probably be all able to help each other a fair bit more than documentation can anyway . Uber also seem pretty good about talking on the forums so we'll probably see them help out the modding community that way too, when they aren't too busy working on the game . All languages can produce memory leaks, and often the ones with automatic memory management are the worst offenders because people tend to just assume it'll all just be magically taken care of for them which isn't the case at all (and is an absolute nightmare to track down), in something like C++ where leaks happen more easily the programmers tend to take more care to avoid it and keep an eye out for it occurring. Though obviously with bad programmers C++ programs can VERY quickly chew up several GB of RAM, at least in a managed language the garbage collection will take care of a lot of that sort of thing for a bad programmer.
I meant that you would assimilate code form other parts of the program, not other programs! :shock: Like taking code from one tank and applying it to another for what ever reason.
Well I don't think the script for a tank is going to be complex enough for it to really matter. But if someone does a total conversation to Starwars or something then I imagine they might not want other people taking their work and creating derivatives from it without at least being credited. Something like this happened to a massive content expansion mod for Neverwinter Nights 2 called Kaedrin's PrC Pack. It added 49 new character classes, 87 new spells, 86 new feats, and made countless changes to the pre existing classes, spells, and feats to bring the game more in line with pen and paper DnD 3.5e. Anyone who is familiar with DnD will understand how massive such a conversion is. It essentially made Neverwinter Nights 2 into an unofficial Neverwinter Nights 3. Long story short, the people who run one of the major player run servers for NWN2 took Kaedrin's PrC Pack, modified it to fit their tastes, and then published the custom changes on their game server despite Kaedrin asking them not to. As a result people like me who prefer to play NWN2 in single player mode can no longer download updated versions of the mod because Kaedrin no longer feels comfortable releasing it to the general public. It is now only available on certain player run servers that Kaedrin has reached an agreement with. http://nwvault.ign.com/View.php?view=nwn2hakpaksoriginal.detail&id=209 So I think we need to foster a spirit of non douchebaggery among the modding community to prevent things like this from ever happening to PA mods as I don't think any sort of legal solution is going to be practical.
I know you weren't implying anything like that and I think that for most mods this won't be an issue. There is probably only going to be one non stupid way to script a tank cannon. I just want the modders who read this forum and the PA community at large to learn from the mistakes of another game mod community.
We do know some of the UI will be HTML. That came up when they first introduced the planet generator. Since Uber want the game to be easy to mod they might release some documentation or an API when we are closer to beta.