Recent Posts

Pages: 1 2 [3] 4 5 ... 10
21
Outpost 2 Programming & Development / OP2 Mission SDK Version 4.0.0 Released
« Last post by Vagabond on May 06, 2019, 05:39:37 PM »
Hey everyone,

I just tagged the OP2MissionSDK at release version 4.0.0. You can find the release code state here: https://github.com/OutpostUniverse/OP2MissionSDK/releases/tag/ver4.0.0. Development will continue against the master branch over time, so if you want the newest library version, go here: https://github.com/OutpostUniverse/OP2MissionSDK.

This release includes changes to all the major projects, Outpost2DLL, OP2Helper, and a bit of HFL.

Over time, if people are looking for a specific new release, please post. Otherwise, sporadic releases may occur naturally over time. I didn't include a static .lib file for the release. If this is desired, please let me know and I'll compile and post.

The release page contains a the list of changes since version '3.5'. 3.5 was never actually released, but covers code changes over a long period of time while the source code was hosted on the SVN server and migrated to Git that were not part of the version 2.0 or 3.0 releases. If you are an old hand with the SDK, you may want to read through the 3.5 release notes to see what changed in addition to the 4.0.0 notes. You can find them in the Readme.md.

If anyone wants to request features or make changes, please post or push PRs against the appropriate SDK library. I'll try to help with reviews to keep the code in good shape or maybe help implement a feature if I feel qualified and motivated to help with the project.

Hooman provided a fair amount of technical help with the release and porting from SVN to GitHub. He also wrote large chunks of the changes in this release, which was all appreciated. Some of the code I committed was rollups of commonly used code in other missions, likely written and refined by Arklon, ZigZagJoe, sirbomber, BlackBox, and others.

-Brett
22
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Vagabond on May 05, 2019, 01:02:03 PM »
Crow!,

I just tested and you can load a modal dialog box into Outpost 2 before passing false back from InitProc. This would allow you to give a custom message. Rising from the Ashes contains a dialog box at the start of the mission that you can use as a template. You can check out Rising From the Ashes here: https://svn.outpostuniverse.org:8443/!/#outpost2/view/head/LevelsAndMods/trunk/Levels/RisingFromTheAshes. In the same repository is Plymouth Cold War, by Black Box, which would be another implementation to check out.

Also, you should read https://wiki.outpost2.net/doku.php?id=op2_sdk:textdialogbox. This article will spell out the basics on getting a dialog box to work (unfortunately, it is fairly complex if you are unfamiliar with resources and the rich text format (RTF).)

see the attached screenshots for examples. The downside is it would produce 2 dialogs. Not sure if you could suppress the second dialog, but I think it would be okay either way?

The quote below is pulled from OP2Archive's Readme. It explains how specific music tracks must be encoded to get working with Outpost 2. I wouldn't be surprised if there were similarly complicated rules for Sound Effects. Unfortunately, I'm not aware of anywhere that the information is stored about the exact format. Maybe you could reverse engineer the settings from an existing sound or maybe someone else could help. Sorry. I do know that Outcasters used custom sound effects, so it is possible.

Outpost 2 audio tracks must be formatted as WAV files with the following settings:
 * Frequency = 22050 Hz
 * Channels = 1 (Mono)
 * BitsPerSample = 16

The file size of each WAV audio track (the actual wav data) must be zero padded to a multiple of 32768 bytes (0x8000).
Output 2 fills the music buffer in 0x8000 size chunks and will not zero fill if a chunk at the end of a file is too short.
If the file is not a multiple of 32768 bytes (0x8000), some garbage data will be played in Outpost 2 before switches to the next track.


Hope this helps,
Brett
23
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Crow! on May 04, 2019, 04:13:47 PM »
OK, the module loaded check in that build of op2ext seems to be working how I want it to for Ohana - the mission already had two different initial setups coded in, depending on a single bool I had been setting to a different value depending on whether I was building the vanilla or PhaseShift version.  So, initializing it with:

Code: [Select]
bool isPhaseShift = IsModuleLoaded("PhaseShift");
Is, in my local tests, correctly building the bases and applying new morale and mining rules according to whether the PhaseShift module is loaded.

It is possible I'd like to have a more understandable error message given to the player for a colony game if I have it refuse to load due to not having PhaseShift active, but I'm not sure if that necessarily has to involve op2ext.


As for the audio issue, I have confirmed that packing the replacement sound into voices.vol placed in the mod's directory causes static when the game attempts to play the sound.
24
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Vagabond on May 04, 2019, 12:46:12 PM »
Crow!,

You should not mix versions of op2ext when playing multiplayer scenarios. I would recommend making a dev copy of Outpost 2 and a regulary play copy of Outpost 2.

Since the function only exists in this new build of op2ext, if you call the new function from a mission DLL with the old op2ext DLL, the game will crash (As it should because it cannot find the function and the application must abort).

Hope that answers your question.

Also, if you return false from initProc, the mission will abort with the attached message. It would be better if a more descriptive dialog popped up saying the given module wasn't present. I have only used modal dialogs on mission startup with colony games. If you want me to play with a multiplayer modal dialog, let me know.
25
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Crow! on May 04, 2019, 12:18:19 PM »
To be clear, if I implement this, will the map crash for anyone who hasn't downloaded this version of op2ext?
26
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Vagabond on May 04, 2019, 06:49:46 AM »
Crow!,

I just posted a beta release of op2ext that allows checking which console modules are loaded.

https://github.com/OutpostUniverse/op2ext/releases/tag/ver2.2.0-beta

You should be able to check if your module is present by calling the following from within the mission's InitProc function:

Code: [Select]
if (!IsModuleLoaded("TestModule")) {
... WARN USER / CLOSE MAP / CHANGE MAP BEHAVIOUR ...
}

Let me know if you need any help setting up.

Thanks,
Brett
27
Um, I am currently finishing up V31, and plan on releasing it tomorrow. Have a bunch of bugs to fix and need to test out the portal code, as it is a fairly significant change to the codebase. I'll do a release here as well as everywhere else.

Lately, I've been only releasing every 2nd build here, as it just seems there is less total interest here on OPU, which makes sense. There has been a lot of really interesting stuff coming from Techcor and Crow! lately, that I figured I'd just wait until the monthly update to release that update here.

Thanks for checking in though!
28
Hey man, what are you working on?

Is there any particular part of the code that you've improved recently, or are trying to improve?
29
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Hooman on May 02, 2019, 05:49:58 AM »
Ahh, sweet! Source code :)


Looks like you're using a slightly outdated level template. Nothing wrong with that. Just wanted to point out there is an updated version at:
https://github.com/OutpostUniverse/LevelTemplate

A few differences with the newer version:
 - A .gitignore file was added, as not all files need to be versioned (*.user, .vs/, Debug/, Release/ ReleaseMinSize/).
 - The old Visual Studio 6 project files were removed. (Version 6 is circa 1996).
 - Main.cpp was split into LevelMain.cpp and DllMain.cpp. Most people only care about LevelMain.cpp. The slow compiling Windows specific stuff usually goes in DllMain.cpp. There was a default HFL init call added to DllMain.cpp.
 - It's pre-setup with an AppVeyor config file for online Continuous Integration builds. (You'd need an AppVeyor account to enable it).
 - Updated APIs with numerous small additions, fixes, and renames.
 - APIs can be updated with a Git submodule update. No need for manual downloading and unpacking.

All of it optional. No need to upgrade, though some changes could potentially make your life a little bit easier.

----

The sound file thing is interesting and unexpected. For game data, I've seen Outpost 2 treat free files the same as stuff packed in VOL files. Not sure why sound would be any different, though this may warrant some investigation. In terms of repacking a VOL file, do you really need to repack the full VOL file, or can you add an additional VOL file?
30
Projects / Re: OP2 Game Flow Redesign (PhaseShift v0.5.0 released!)
« Last post by Vagabond on May 01, 2019, 08:38:00 PM »
Crow!,

I did some research on your sound issue. Outpost 2 will not pick up individual sounds placed loosely. It looks like you have to bake the sound effect into sound.vol.

I recommend packing your sound effect into sound.vol. Then you can place the modified sound.vol into your mod directory. Outpost 2 will pick up and load your sounds instead of the default when the mod is detected. You can use OP2Archive to do the packaging. Beware that it has outstanding directory selection issues that I still need to clean up. So you might have to get creative and command the package from a relative or absolute directory or something to get it to work. Sorry, but I made some poor decisions on how XFile was coded and have been working other things instead of cleaning it up. If you have too much trouble, I'll focus on fixing it.

op2ext currently has 2 outstanding bugs that are in PRs. If these get merged in, we should be ready for you to take a beta build of it and test the ability to detect the module name. I'd like to continue beefing up the unit tests some more if I find some time.

Let me know how the sound effect integration goes. I suspect it may be coded incorrectly and play as static once you get Outpost 2 to detect it. I tested by overwriting the sound effect Tokamaks play when you click on them.
Pages: 1 2 [3] 4 5 ... 10