Announcement

Collapse
No announcement yet.

How To Distribute Mutators?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #31
    The process you're using is overly complicated.

    I had a chat with Flagg at epic as I really want to see why you're having all of these issues that don't appear to make sense.

    Nothing you do should ever require touching that dummy exe file at all.. all the content should be retained within a plugin, or with the plugin calling content out of Content/ChaosUT/XXXXX, it should still never do what what you're listing..

    Can you hit me up on irc at some point? I'd like to try see if this is unique to your codebase or not (I'm about to start building out an online-compiler/cooker for the community with RushPL)

    Comment


      #32
      Thanks very much. I only do this in my spare time as other activities permit so I would be going at this tonight about 9 or 10 pm eastern time usa. I can try to find you on irc then. WinGrep has proven that the mutator is inside the exe file, the version string is clearly in there, words like 'ChaosUT' and chaos method signatures are inside of it. I would be glad to start with a plain vanilla exe again but am not able to obtain one, as the last time I synced by branch to Main, the exe does not run on my machine and seems to be a 32 bit or other version sitting in the Win64 area. At any rate, it won't run so i can't use it. I do not have any original backup of this file to go back to, only the dirty exe which has all this 'Chaos' stuff in it.
      Last edited by warhead328; 11-14-2014, 02:08 PM.
      Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
      The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
      https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

      Comment


        #33
        Yep, I'm a bit at a loss as well. The steps I indicated above will get you building plugins, the MakeUTDLC command can help you package up content. You should be able to build for the packaged alpha. That being said it is really complicated to do it right now and it's not for the faint.
        HABOUJI! Ouboudah! Batai d'va!
        BeyondUnreal - Liandri Archives [An extensive repository of Unreal lore.] - Join us on IRC [irc.utchat.com - #beyondunreal]

        Comment


          #34
          Haven't made it through all the posts yet. But do want to point out that I don't recommend trying to do any mod development with Launcher (aka Rocket) builds. You need github engine source to make modular (non-monolithic) builds.
          http://twitter.com/PeteNub/

          Comment


            #35
            ye, can confirm that. using knepleyp github engine source and latest main branch ut source. however, that being said, I had been using launcher engine in the beginning but then switched to knepleyp. I would wonder if using the launcher in the beginning has adversely affected something? if so, the need would be to start again with a clean UT, and I do have such an area, but as I mention above, the exe file in that area is not usable, and so I still would need to get a good copy of the proper exe to test with. I have not tried resyncing in several days, so perhaps someone has fixed that issue, I would have to try a resync tonight to see.
            Last edited by warhead328; 11-14-2014, 07:28 PM.
            Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
            The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
            https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

            Comment


              #36
              Originally posted by warhead328 View Post
              ye, can confirm that. using knepleyp github engine source and latest main branch ut source. however, that being said, I had been using launcher engine in the beginning but then switched to knepleyp. I would wonder if using the launcher in the beginning has adversely affected something? if so, the need would be to start again with a clean UT, and I do have such an area, but as I mention above, the exe file in that area is not usable, and so I still would need to get a good copy of the proper exe to test with. I have not tried resyncing in several days, so perhaps someone has fixed that issue, I would have to try a resync tonight to see.
              That exe file is nothing more than a placeholder to stop something in the engine from complaining, you don't use it, and shouldn't need to use it at all.. you should be getting a plugin out of it, and you give that plugin and its contents to other people to put in their builds that they download from epic.

              Comment


                #37
                Much thanks to Raxxy for helping me to get this process working.
                I want to shout out about Raxxy, as he has gone above and beyond to help me out and has been beyond professional.
                A big Thank You to Raxxy!! You rock!
                Thanks everyone for the help. Raxy and Pete are as we speak working on further mods to smooth more things out and fix some issues that Raxxy found, so good things to come.

                Here is the process and knowledge for me getting a release cycle going for Win64. I will update this as I see mistakes and needed refinements.
                Some of these things may be obvious to some but not to a beginner like myself, and i'm including points i found helpful to get going.
                I'm putting everything i can into a single concise post in hopes of detailing the whole process and what it takes, to help new people who come after me.
                Possible to make some kind of Sticky thread or put on Wiki to make this info easy to find?

                I will assume it is already known how to get and compile the ut source, so will not include those steps here.
                Staged builds using ue4 Package tool and BuildCookRun seem to be not working quite right at the moment, at least not for me, so not going down that path.
                Raxxy has steered me down path to using the pre-alpha downloaded build instead.
                I'd prefer the staged but will go with what Raxxy says, as he knows better than I.


                *****

                Getting the correct Engine and UnrealTournament branches:
                You can either use the Github Clone button to get the initial source code to your machine, or issue in Git Shell(desktop icon) the command 'git clone URL', where URL is the url of the source code resository in Github.

                Epic team generally puts out a new alpha release on Thursday evening, so check this page
                https://forums.unrealtournament.com/...Playable-Build
                Ignore the official date in the post and instead check the last date edited to see if they put out a new release.
                Generally you can check Friday morning to see if they put one out.
                If so, you can resync in github to get the latest code which is compatible with that alpha (using the Github desktop icon there will be a resync button).

                Alternatively you can check out a specific commit.
                If you don't know the commit id, you can click on the Commits link to view the commit history, and click on a commit for the proper date of when the release was put out.
                At the end of the browser Url there will be a big string of letters and numbers (after the last slash /).
                This is the tree id which will give you the entire source code branch at the time of that commit.

                Once you have the commit id, you must invoke the Git Shell(does not seem to be any user interface in Github for this so must use the Shell and issue a command line) and then change directory to where your cloned source is, and then issue the command: 'git checkout COMMIT_ID', where COMMIT_ID is the commit id (just the letters and numbers, no slashes).

                If you are already working on your plugin in an existing checkout, before checking out a new branch, generally git hub forces you to undo all your changes first, else it refuses to checkout. Before doing that, make sure you have backed up any of your existing plugin files, or you will lose them. << Very Important

                Sometimes github errors out saying it can't find the branch. If so, make sure you undid all your existing changes, and verify the commit id. If still erroring, you may have to re-clone from scratch.

                After checking out, if you had made a backup of your plugin, restore it now.

                Regenerate the project files to make sure the visual studio solution reflects all the latest files, then you can Build the solution.

                Getting the correct Engine branch:
                The Epic dev team uses the engine branch at https://github.com/EpicGames/UnrealEngine/tree/4.6
                (no longer using https://github.com/knepleyp/UnrealEngine)
                This is the branch used for the pre-alpha downloaded build, and also has the latest mod build tools, so if you are making a mutator you must use this branch.
                This will ensure that you are compatible with the alpha.

                Use the steps in prior section to get the correct branch.
                If you are just resyncing and not checking out a specific commit, make sure you select the 4.6 branch from the drop down in Github, or alternatively you can issue the Git Shell command 'git checkout 4.6'.
                They do not post the link to the engine commit they used for the alpha, so you must either resync at the right time, or browse the commit history for a commit from the release date.


                Getting the correct UnrealTournament branch:
                They use the default branch for the alpha, so Clone the repository and no need to switch branches, and then either sync up after they release an alpha, or get a specific commit using git checkout command(see prior section's steps).
                On the alpha download page in the second post, they post up the specific link to the commit on which the alpha was built, so if you like, you can take that commit id from the end of that url and use the git checkout command to get it (no need to browse commit history).


                Setting up the engine branch:
                Beyond the usual engine setup stuff, you also must make a junction link to UnrealTournament uproject folder inside the UnrealEngine folder (so the link is in same directory as Engine) like so.
                In a command prompt in the UnrealEngine folder:
                MKLINK /J UnrealTournament K:\ut4\UnrealTournament\UnrealTournament, where that k: path is your path to ut proj file.

                Run the batch file called 'Setup' in the UnrealEngine directory which will automatically download and install the prerequisites.
                This used to be optional and you could download prereq's separately, but now seems to be a required step.

                You need to edit Engine\Source\Runtime\Launch\Resources\Version.h
                and set the define of ENGINE_VERSION to the build number for the alpha you want to use.

                You can get the build number from the name of the alpha's zip file, which has a number in it's name.

                Some people say they also set BUILT_FROM_CHANGELIST to the build number, but currently I am setting
                this to zero, and also setting the second definition of MODULE_API_VERSION in Engine\Source\Runtime\Core\Public\Modules\ModuleVersion.h, like below
                #if BUILT_FROM_CHANGELIST > 0
                #define MODULE_API_VERSION 2369412
                #else
                #define MODULE_API_VERSION <YOUR BUILD VERSION NUMBER>
                #endif

                So two approaches are above, use the one that works for you.

                If you do not get the build version set correctly, then you will get a version number error when trying to run the plugin in the alpha.


                Setting up the UnrealTournament branch for your mutator:
                Basic instructions for setting up a mutator are here https://wiki.unrealengine.com/C%2B%2B_Mutator_Tutorial
                You may have created your mutator from scratch inside the UT solution, or like myself you may have gotten the mutator source code from another source and need to install it into the solution.
                If the later is the case, use the Regenerate project files option to install the mutator into the solution after you have copied your mutator files to the proper places in Plugins and Content directorties.
                Your mutator should now show up in the visual studio solution.

                If your mutator has Content (graphical assets), put them in Plugins\PLUGINNAME\Content, not UnrealTournament\Content.
                To view plugin content in the editor, use the Content Browser View Options and make sure the checkbox to show plugin content is checked.
                You should not have your content in the UnrealTournament\Content directory, or else your content may not package up properly by the MakeUtDlc utility.
                This is because most all of the plugin content is packed, but in the other directory, only content is packed which are referenced by the c++ classes.
                Therefore if you had a mutator blueprint, it would not package up unless it was in the plugin area.


                Running the mutator in editor:
                When you run the UnrealTournament project it starts the UE4 editor with Example_Map.
                To run the mutator, click the arrow on the right side of the Play button to get into the settings, go to advanced settings and in the server game options
                enter ?mutator=PLUGINNAME.PLUGINNAME, or ?mutator=PLUGINNAME


                or, when you start the game, you could use a console command like this to switch the map and mutator:
                open DM-Circuit?mutator=PLUGINNAME.PLUGINNAME

                mutator=PLUGINNAME should also work

                you can use Game=DM, Game=CTF, etc to specify a game type, but DM is default.

                This shorthand notation doesn't seem to work for mutator blueprints which are not part of stock UT, so mutator=BLUEPRINTNAME may not work (probably this will be fixed soon), and if not, just specify the full path, ie, mutator=/your path/BLUEPRINTNAME.BLUEPRINTNAME_C



                Packing up the mutator and running in alpha build:
                Use the MakeUTDlc command as outlined on this page https://wiki.unrealengine.com/Cookin...eal_Tournament)
                Granted as already pointed out in this thread, there are issues with this utility packing too many files.
                This will make DLL binaries and a Pak file(containing your content from Content directory).
                As the wiki page outlines, your files will be located in the Saved\StagedBuilds area.

                For single platform builds, copy Saved\StagedBuilds\PLUGINNAME\WindowsNoEditor\UnrealTournament to the target alpha WindowsNoEditor folder.

                The wiki says to use Saved\StagedBuilds\PLUGINNAME\PLATFORM\UnrealTournament folder.
                This is only true if you do a multi platform build, such as -platform=Win64+Win32.

                For single platform, ie, -platform=Win64, the directory is PLUGINNAME\WindowsNoEditor\UnrealTournament.

                For dual platform build the pak file is not named correctly, and so you need to rename it to PLUGINNAME-WindowsNoEditor.pak.
                Running dual platform for the very first time will error out with a strange error saying it can't find a pak file.
                To fix this, run a single platform build first, and then the error will go away.

                If you are building for two platforms this creates two completely separate PLATFORM directories under StagedBuilds\PLUGINNAME. Seems somewhat undesirable. Better to to use the single WindowsNoEditor directory where you have specific binary directories named after the platform, and then you only have to copy ONE master directory to make your release (this would assume the pak file is not platform specific, which i don't think it is or they should have a platform specific directory for it like they do with binaries).

                You can use the RunUT.bat file in the alpha to run ut and use a console command to switch to your mutator.

                You can also make a batch file that runs the mutator from the command line, such as:

                start Engine\Binaries\Win64\UE4.exe UnrealTournament DM-Circuit?game=DM?mutator=PLUGINNAME -SaveToUserDir
                exit


                If you don't have stuff in Content directory and just need to build the binaries (which must start with 'UE4-'), then one of the following can be used:

                C:\dev\UnrealEngine\Engine\Build\Batchfiles\RunUAT.bat BuildCookRun -project=C:/dev/UnrealTournament/UnrealTournament/UnrealTournament.uproject -noP4 -platform=Win64 -clientconfig=Development -serverconfig=Development -nocompile -build -server -serverplatform=Win64 -skipcook -NoCompile
                (change the paths accordingly, binaries should end up in your plugin directory)

                Switching from 'Development Editor' to 'Development' and rebuilding

                Following instructions at https://wiki.unrealengine.com/How_to..._with_commands (haven't tested this one out too much yet but the above buildcookrun definitely works)



                Feedback on the process so far:
                -Currently the process seems fairly complex. Lots of bits and pieces of knowledge to gather up to do this correctly. Whatever Epic comes out with, I think i speak for all: Make this process simpler and easier to learn. I am quite certain they are endeavoring to do so.

                -It has been mentioned the path of doing staged builds is complex, but i feel doing staged build is simpler. Doing a staged build, a developer can just release a stable version of UT which works with their mutator and be done with it, with none of the complexities of syncing up to the branches the epic dev's are using. I would like to see the staging process fixed so that we can also do it that way if we would so choose.

                -Currently no project files are in github. This means you need to do the "Regenerate project files" step a lot. I am sure there are reasons to not having the project files in github, but this seems a cumbersome and non intuitive step. It's not intuitive to a mutator programmer to have to run a step that is done to setup UT when all they want to do is install their plugin. It's not intuitive to have to do this step every time you sync a branch. In my years of working with TFS and visual studio, i have never had to do anything like this. Granted visual studio project file management and merging changes to them is a mess thanks to Microsoft so maybe that's why it is done this way.

                -I would prefer mutators to be in their own project, separate from the UT source. I understand that their are additional complexities to Unreal Tournament over your normal visual studio solution, but the industry standard is to dynamically link to DLL files and not need source code, thus the name 'Dynamic Link Library'. When working with any third party software, you do not need their source code, only their DLL's. Having the mutator as part of the UT source forces visual studio to iterate over all the UT source files many many times and this never stops, thus adding time and complexity to the mutator dev cycle. Having in separate project you can avoid all this, avoid steps like "Regenerate project files", and make the mutator easier for one dev to hand off to another. The next dev who takes the project over can simply unzip the package and load it up the project, simple as that. There are also dangers in having mutator source code in UT source code area, as one time github told me it could not resync due to uncommitted code and demanded that i throw away all my uncommitted changes, which then promptly deleted all my mutator source code

                -We could use a single place where the entire mutator process from start to finish is outlined and easy to find(Wiki?). Most of my struggles are simply gaps in my knowledge due to being new. To get where I am at today, it has taken lots of web searches, forum posts, and conversations, but good to just have a doc which says it all, which people are directed to. Granted these steps will change over time, which means that doc has to be kept fresh. As far as I can tell, existing documentation on Wiki is not complete, not mentioning things like the MkLink command, the engine branch the alpha uses, how to get the alpha ut branch, and etc etc.
                *Update: Improvements to the Wiki are coming, looking forward to that.

                -MakeUTDlc seems to be sometimes causing visual studio to reparse all the header files again when you load up the UT solution afterwards. This is time consuming. MakeUTDlc quite often compiles much UT source code in addition to your plugin. Not desirable. It should only compile the plugin and having to iterate over all the other files is very time consuming. Also see the issues with MakeUTDlc in the packaging steps outline above.

                -Having to wait for a particular date and time to sync your branches seems edgy. If there is an issue at Epic which prevents deployment, you have synced your stuff already and quite likely made it incompatible with the current alpha. Browsing commit history and doing specific checkouts also is somewhat complex and subject to user error so wish there could be an easier way. No sweat for the Vet but daunting and learning curvy for the beginner. Currently they post the commit id for the UnrealTournament area but not for the Engine, so would be good if they would post up both links.

                -Having to edit version.h and possibly moduleversion.h is not desirable. I understand reasons given to me about how the engine is generic and needs to be such because all kinds of people use the engine, so we can't just be stamping the alpha version into github source, but that exactly proves my point that you shouldn't then have to edit it. the engine is the engine and has nothing to do with whatever game is written to use it. we shouldn't be stamping a game specific version into it at all and need to change the scheme of how things are done.
                Last edited by warhead328; 01-02-2015, 01:21 PM.
                Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
                The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
                https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

                Comment


                  #38
                  Wow, that is rather convoluted. Though if that's what it takes shouldn't this be put in a sticky?
                  Last edited by Crafty; 01-10-2015, 06:38 PM.
                  C++: Spray prototype | Compilation Tweaks | Maps: Quayside (inactive)

                  Comment


                    #39
                    the issue is that this info gets outdated almost every week. at best, it's only temporary stuff to help get us by in these earlier stages. raxxy is working on a wiki page which will give a much better outline of how to do it, and when that comes, it will be the place to go, not here. until the wiki page comes out for it though a sticky would be cool. when I first came on board it was not pleasant digging around for info on how to do this stuff.
                    Last edited by warhead328; 01-14-2015, 04:29 PM.
                    Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
                    The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
                    https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

                    Comment


                      #40
                      Originally posted by warhead328 View Post
                      the issue is that this info gets outdated almost every week. at best, it's only temporary stuff to help get us by in these earlier stages. raxxy is working on a wiki page which will give a much better outline of how to do it, and when that comes, it will be the place to go, not here. until the wiki page comes out for it though a sticky would be cool. when I first came on board it was not pleasant digging around for info on how to do this stuff.
                      Well, the biggest problem you had IMO was going to hotfix builds too fast. When I finally went to 4.6.1, I had the same issues that you had and had to figure out how to solve them. That ModuleVersion issue hadn't been an issue prior to that build.

                      The steps for building plugins are pretty simple, I do just about the same thing every week to get my plugins built and distributed. But you have to be ready to run into a few problems along the way. Asking for solutions on IRC helps because the feedback is more immediate and we don't have to keep doing this back and forth dance on the forums to figure out what is going on. This is how raxxy and I have fixed or worked around many issues.
                      HABOUJI! Ouboudah! Batai d'va!
                      BeyondUnreal - Liandri Archives [An extensive repository of Unreal lore.] - Join us on IRC [irc.utchat.com - #beyondunreal]

                      Comment


                        #41
                        Plz clarify "too fast"? I upgraded to 4.6 engine branch when told to do so (which was done using other means than the forums, which does indeed help) and this also was about when the official announcement was made on the forum. Not sure there is any other way? What is your recommendation?
                        Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
                        The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
                        https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

                        Comment


                          #42
                          No recommendation, I'm just explaining why you had problems that nobody else knew about. That freaking ModuleVersion.h file is the bane of my existence. I really don't understand why there are two places to set the plugin version, even if it is for backwards compatibility ****. It's confusing.

                          Anyway, the day 12/19 build came out 4.6.1 wasn't available so most of us were still using 4.6.0. 4.6.1 was a hotfix so they changed the module version for whatever reason. Next time I will know better how to help you when you're having problems.
                          HABOUJI! Ouboudah! Batai d'va!
                          BeyondUnreal - Liandri Archives [An extensive repository of Unreal lore.] - Join us on IRC [irc.utchat.com - #beyondunreal]

                          Comment


                            #43
                            yea, trying to understand how i was on a different version than others. I want to get any holes out of my process if I can.

                            My issues were reported using the 12/12 build.
                            all I did was switch to branch 4.6 (that branch epic announced they had switched to). Epic's announcement of 4.6 branch was 11/18 and judging from my posts in other threads, I had switched to this approx. dec 12 for the 12/12 build, and then it took me almost a week to figure out the module version issue. raxxy and I had been working on it and hadn't come up with anything so that's when I posted about it in forums.
                            as far as I know, I switched at the appropriate time, having had a heads up about it from raxxy, and shortly after, an official announcement was made. I switched sometime shortly after the announcement, but guessing approx. dec 12.

                            so, had you been using a different branch of the engine, or just had not resynced yet? My best guess is you were still using the knepleyp branch? if so, that explains it.
                            Last edited by warhead328; 01-20-2015, 01:09 PM.
                            Bombing Run for UT3 Coder https://forums.epicgames.com/threads...ease-Candidate
                            The Reliquary TRBP team Coder http://unrealtournament2004.filefron...tEffects;92208
                            https://www.youtube.com/channel/UC0p...Q7l8s-0ug_Etgg

                            Comment


                              #44
                              I'm not sure when 4.6.1 came out. Before 4.6.1 came out that ModuleVersion.h file wasn't a problem, that's why I'm assuming it was tied to that.

                              That being said, switching engine versions is always a pain. I went ahead and got set up on 4.7 so I'll be ready for the next build but the latest version of UT doesn't work with latest 4.7 source. So more problems... I don't tend to keep my engine up to date, I try to stay in roughly the same revision range that Epic does and they don't tend to move around a lot when they are on a mainline version. I'm starting to think they move to the next version too soon, though
                              HABOUJI! Ouboudah! Batai d'va!
                              BeyondUnreal - Liandri Archives [An extensive repository of Unreal lore.] - Join us on IRC [irc.utchat.com - #beyondunreal]

                              Comment

                              Working...
                              X