Author Topic: Problem Finding Templates  (Read 3082 times)

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« on: November 16, 2008, 11:59:09 PM »
Okay, if I read the instructions and did them properly, I should be up to Installing the OP2 SDK.

At the part where I'm supposed to "Go into the folder you just unpacked, and open the \CB_Templates folder," I was stumped. I looked into the folder and found no such thing as the \CB_Templates folder.

I'd really love to start making OutPost 2 maps so I can play because the original colony games eventually got boring and I really need help finding this templates folder.



Where can I find it? Thanks in advance!

P.S. I'm sorry if this is the wrong place to put this.

The Conestoga  :op2:
« Last Edit: November 17, 2008, 12:17:23 AM by Conestoga »
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."

Offline Hooman

  • Administrator
  • Hero Member
  • *****
  • Posts: 4955
Problem Finding Templates
« Reply #1 on: November 17, 2008, 01:02:16 AM »
I assume those are Code Blocks specific versions of the templates, which may use different paths to library or header files. I'm not sure about that folder, but you do have templates there. The "Multiplayer" and "Multiplayer Hooville" folders are template C++ level projects. They were probably designed for use with Visual Studio. Depending on your setup, you may need to adjust some paths, or switch between the "" and <> form of #include. (The double-quote form uses paths relative to the file being compiled, where as the angle-bracket form searches from some system defined path).
 

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« Reply #2 on: November 17, 2008, 01:28:01 AM »
Quote
I assume those are Code Blocks specific versions of the templates, which may use different paths to library or header files. I'm not sure about that folder, but you do have templates there. The "Multiplayer" and "Multiplayer Hooville" folders are template C++ level projects. They were probably designed for use with Visual Studio. Depending on your setup, you may need to adjust some paths, or switch between the "" and <> form of #include. (The double-quote form uses paths relative to the file being compiled, where as the angle-bracket form searches from some system defined path).
Well the instructions on the Wiki did say to copy everything in that templates folder which should've come from the op2_dllsdk ZIP folder which was provided.

With the information you said about the C++ files, should I Cut & Paste those into the CodeBlocks file as the Wiki said?

The Conestoga :op2:
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."

Offline CK9

  • Administrator
  • Hero Member
  • *****
  • Posts: 6226
    • http://www.outpost2.net/~ck9
Problem Finding Templates
« Reply #3 on: November 17, 2008, 09:45:33 AM »
Installation of the mapper instructions?  Don't follow them to the letter, they aren't 100% accurate.
CK9 in outpost
Iamck in runescape (yes, I still play...sometimes...)
srentiln in minecraft (I like legos, and I like computer games...it was only a matter of time...) and youtube...
xdarkinsidex on deviantart

yup, I have too many screen names

Offline Hooman

  • Administrator
  • Hero Member
  • *****
  • Posts: 4955
Problem Finding Templates
« Reply #4 on: November 17, 2008, 09:59:45 AM »
Hmm. I don't use CodeBlocks, and it's been ages since I've read anything on the Wiki. I'm not too sure about anything CodeBlocks specific.

Although, the CodeBlocks package uses the Microsoft C++ compiler. When those wiki instructions were written, it was to get the Visual Studio 6 C++ compiler to work with CodeBlocks as the IDE. I just use the Visual Studio 6 IDE when working on Outpost 2 things. You can also download Visual Studio 2008 Express Edition for free from Microsoft if you wanted to try that.

At any rate, the source code files should stay largely the same, except for possible path adjustments. The project files however, will change between IDEs. If you cut & paste source code, you may miss some of the project file settings. However, I don't think any of them are too terribly important. I remember the image base was changed to ensure the levels loaded faster, but that's just an efficiency thing. You can probably get away with some cut & paste. Just make sure it's being put into a DLL project.


Perhaps a CodeBlocks user could provide more help on the subject.
 

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« Reply #5 on: November 17, 2008, 03:11:24 PM »
Quote
Installation of the mapper instructions?  Don't follow them to the letter, they aren't 100% accurate.
With that said, what should be my course of action into installing this map maker?

The Conestoga :op2:
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."

Offline Sirbomber

  • Hero Member
  • *****
  • Posts: 3238
Problem Finding Templates
« Reply #6 on: November 17, 2008, 07:05:06 PM »
Just to be sure, you realize that OP2Mapper (make .map terrain files) and the SDK (make .dll mission files) are two very different things, right?
"As usual, colonist opinion is split between those who think the plague is a good idea, and those who are dying from it." - Outpost Evening Star

Outpost 2 Coding 101 Tutorials

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« Reply #7 on: November 17, 2008, 07:59:08 PM »
Quote
Just to be sure, you realize that OP2Mapper (make .map terrain files) and the SDK (make .dll mission files) are two very different things, right?
Yes I do understand they are different, but these Wiki instructions are awful confusing. Basically, I just wish to make Outpost 2 maps with missions so I can play them.

If you have any better ways to do this or have another program that makes Outpost 2 maps playable, I'd be grateful to know.

The Conestoga :op2:
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."

Offline Hooman

  • Administrator
  • Hero Member
  • *****
  • Posts: 4955
Problem Finding Templates
« Reply #8 on: November 17, 2008, 11:29:05 PM »
I'm afraid you'll just need to use the Microsoft C++ compiler to make the DLL, and the current map editor for the .map file. I know these aren't the easiest tools to use for some new people, but there aren't really any alternatives.

The game was just designed to use executable code to create levels, rather than any kind of script or data set. Plus, since the name decoration/mangling used by the Microsoft C++ compiler is proprietary, it's the only compiler that can use the symbols exported by Outpost2.exe correctly. There's also the matter of calling conventions too. It might be possible to write a level DLL with the correct exports using a different compiler, but it probably wouldn't be able to import any of the Outpost2.exe symbols, which would make the DLL pretty useless.

The map editor can also use a bit of work and upgrades. We've had a few ideas to improve it, but the people with the skill to do it usually don't have the time to work on it.  

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« Reply #9 on: November 18, 2008, 12:24:26 AM »
Well I have the .map file I want developed, but it seems I should just discard CodeBlocks and just use the compiler.

That really saves the time for trying to configure it properly, but I'll need a whole new set of instructions on how to make a level DLL using the compiler and not the CodeBlocks.

If its not too much to ask I hope, is there somewhere I can be directed to use the Compiler for making missions/scenarios and/or installation instructions?

The Conestoga :op2:
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."

Offline Hooman

  • Administrator
  • Hero Member
  • *****
  • Posts: 4955
Problem Finding Templates
« Reply #10 on: November 18, 2008, 03:50:19 AM »
Err, CodeBlocks uses the compiler. CodeBlocks is basically a fancy text editor. You could use Notepad if you really wanted. But the nice thing about CodeBlocks, or other IDEs, is that they usually provide nice syntax highlighting, and have some built in "build" button that will run the compiler on your code. Sure, you could just install the compiler and run it from the command line, but I'd suggest using some kind of IDE. Either CodeBlocks or Visual Studio are your main chioces for an IDE.

Running the compiler from the command line doesn't really free you from setting up the compiler either. It still needs to be installed somewhere, and the libraries and header files have to exist in some folder. Plus you still need to work on your project, and somehow make references back to those libraries and header files.


I can maybe look into this furthur, but I'm pretty busy over the next few days. If someone else who uses CodeBlocks isn't able to help, you'll probably be waiting at least a couple of days before I can give a useful answer.
 

Offline Conestoga

  • Newbie
  • *
  • Posts: 24
Problem Finding Templates
« Reply #11 on: November 18, 2008, 10:18:39 AM »
Okay, thanks a lot. (thumbsup)

The Conestoga :op2:
Robert E. Lee - "Get correct views of life, and learn to see the world in its true light. It will enable you to live pleasantly, to do good, and, when summoned away, to leave without regret."