Jump to content

Newbie issues


Recommended Posts

Hi everyone. I want to access the game files and I have this issue: I have done everything until the install of ​Visual C++ 2010 Express Edition and, following that, I don't understand the instructions very well...

And for the record, my knowledge of programming and necessary softwares is rather limited (some C and C++). I'm doing this because I like the game and what it can potentially achieve. It's also a way to learn more programming (I usually learn better if I like the subject and/or its uses).

Link to comment
Share on other sites

Hi, are you following these build instructions?

If you have already checked out the game from SVN and installed VC++ 2010, you're most of the way there :) Maybe you can explain a bit more which part you don't understand or what is going wrong?

Hi. Yes, I am following that. My doubts begin here:

The Visual Studio project/solution files are automatically generated from the source files:

  • Run build/workspaces/update-workspaces.bat.
  • Open build/workspaces/vc2010/pyrogenesis.sln. (Use the vc2008 directory for VC++ 2008; use the vc2010 solution for VC++ 2012 and choose to upgrade the projects.)

Build configuration

Make sure to select the "Release" configuration to build an optimised, more playable version of the game (the target will be pyrogenesis.exe). The "Debug" configuration can be more useful for debugging but has significantly reduced performance (the target will be pyrogenesis_dbg.exe). Both "Release" and "Debug" builds include debug symbols, see Debugging on Windows for more details on debugging.

Now you should be able to build the code from within Visual Studio, using "Build Solution" (F7).

That .bat file I have to run: what is it and where is it?

Where do I select those "Release" and "Debug" configurations?

Where and what is "Build Solution?

Edited by Ryze
Link to comment
Share on other sites

That .bat file I have to run: what is it and where is it?

It's a script that creates the files needed to build the game. The path "build/workspaces/update-workspaces.bat" is relative to your SVN checkout of the game. If you don't see this file, then maybe your SVN checkout didn't complete successfully, and you should do an SVN update to continue it.

Where do I select those "Release" and "Debug" configurations?

After you run update-workspaces.bat and open "build/workspaces/vc2010/pyrogenesis.sln" in Visual Studio, you will see a "Debug" dropdown in the toolbar. You will want to change that to "Release" most of the time. It looks roughly like this: http://social.msdn.microsoft.com/Forums/getfile/69721

Where and what is "Build Solution?

That compiles the game, you can either press F7 or use the Build menu. You can't do these steps until you have completed the first ones.

Link to comment
Share on other sites

Thanks for the explanation. I managed to do all that.

The last steps are optional, aren't they ('Building Atlas', 'Running')? Only needed if I want to mess with the map or test my changes in-game, right?

You can still run Atlas, but you won't be able to modify it unless you follow the other steps (building wxWidgets, etc.)

Link to comment
Share on other sites

You can still run Atlas, but you won't be able to modify it unless you follow the other steps (building wxWidgets, etc.)

Map changing doesn't appeal to me that much...

I've been semi-randomly opening files and... Jesus... It's overwhelming! So many files, and big files at that! The amount of work is awe-inspiring! I bow before all those that worked in this game, the level of dedication must be fenomenal...

Even though C and C++ are the languages I have worked with, I barely understand any file at all! True, my knowlegde of C and C++ is laughable, but... so many functions, so many libraries...

I am rambling right now, I need to stop writing :D

P.S.: What file(s) contain AI behavior? I've been searching, but the ones I opened were the 'managers', I think. Nothing specific... (then again, I barely understood them, I'm might be mistaken)

Edited by Ryze
Link to comment
Share on other sites

AI is handled in Javascript (as most of the game logic is). Only graphics, and common cpu-intensive parts are in c++.

For the AI, you should look in binaries/data/mods/public/simulation/ai. There you find the different AI logics. Some of the shared functions are also in C++, that are the managers you found.

Link to comment
Share on other sites

P.S.: What file(s) contain AI behavior? I've been searching, but the ones I opened were the 'managers', I think. Nothing specific... (then again, I barely understood them, I'm might be mistaken)

Check out Modding Guide and Finding Your Way around. Most of the data files (XML, JS, JSON) can be edited with a text editor, I would recommend Notepad++ on Windows.

Link to comment
Share on other sites

Also note, there's a big difference between Java and JS (JavaScript). If you ever use google to search how to do something, make sure you end up on pages explaining JavaScript, and not Java. Although it looks similar on first view, there are enough differences to make you pull your hear.

Thanks for the warning.

Link to comment
Share on other sites

I am in a similar situation to Ryze. Would love to get involve but just really do not know where to start. I have downloaded the source code and set-up the build environment and all that but now I want to learn how to edit the files correctly. I have a basic knowledge of a few languages (C++,Java,Python) but nothing really spectacular. I would love some tips on where to start. Thanks.

Link to comment
Share on other sites

If you have no specific knowledge, best might be to start with gameplay logic. This is quite easy if you know the game. Every entity (unit, building, plant, mine ...) has a template (in binaries/data/mods/public/simulation/templates). That template consists out of components that describe the behaviour and statistics (a health component, an armour component ...). When you want to fix something in gameplay, you search the right component to edit, and edit the code for that. Note that performance critical components are defined in C++, while other components are in JS.

Also look for the easy tickets in trac: http://trac.wildfiregames.com/report/16

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...