Tuesday, March 3, 2015

Unreal Engine 4 free - HTML5 weirdness in 4.7.1

Epic announced a refund, free asset store money to subscribers and free Unreal Engine 4.

https://www.unrealengine.com/blog/ue4-is-free

Well. That's pretty damned awesome indeed.

I tested out the HTML5 publish last night and had interesting results.
Chrome - fine
Firefox 34/35 - fine. 36 - broken.
IE - it hates HTML5 so I don't care right now.

All in all, it's pretty easy, fast and a small project clocks in at about 50MB, my Azure hosting crunches that down to about a 22MB download.

Pretty damned awesome.

Tuesday, January 13, 2015

Connect Four - the giant verrsion

UE4 blueprints. 24MB download here http://quiet.net.nz/content/connectfour.rar

No AI or menus, just taking turns at dropping bars. Occurs to me I didn't check for stalemate, oh well.

Note for future, write the logic in code next time.

Sunday, July 6, 2014

Choice

A thing I have made http://www.quiet.net.nz/Games/Play/Choice
I wanted to do a step by step idea and see how I would translate that into a 2d game and what things take time and more planning than usual. It was about 2 nights work, lots of time spent on "art" and realising that planning out the game flow is really important instead of bolting extra bits on.

6 random endings, turn the key or don't. You might not die.

Saturday, June 21, 2014

Building Unreal Engine HTML5

Update: 4.7 has HTML5 publishing all built in now apparently (I've not tested) so the below is old, just nab a new sub from Epic :)

Almost all the information needed is contained in this link https://answers.unrealengine.com/questions/18136/html5-build-firefox-cant-find-the-file-myprojectht.html

It's spread around a bit, but here is the list I ended up with:
Unpack the 4.2 source, required 1/2 and optional files and regenerate the project.
While this is happening, install emscripten (I used the self installing version which set my environment up perfectly) and grab XAMPP install and the Nightly Firefox 64bit build.

Once the source is ready, open it and find HTML5Platform.Automation.cs (Programs/Automation) and change the string in line 36 to read "/c python {0} {1} --preload . --pre-run --js-output={1}.js" as per Ehamloptirans instructions in the main link.

If you don't you may get Windows asking "how do I open a .py file?". Python is installed with emscripten but isn't called correctly (the log will show this when you try and build later if you don't fix it).

Build the development version of UE4.2. This took around 40 minutes on my pc, didn't bother the RAM much but did like the 8 cores a lot.

Now build UnrealFrontend. This is the tool that is actually used to build your HTML5 setup.

Open your project once, cook the content, save it. Go into your projects folders in explorer, into the Config folder and open up DefaultEngine.ini. Here is where you can set your GameDefaultMap, but in order to fix an HTML5 running issue, add this (or just the line if [Plugins] exists.)
[Plugins]
-EnabledPlugins="ExampleDeviceProfileSelector"

I had to search the source code to find that other engine.ini samples remove this specifically. HTML5 version was throwing an error when I attempted to run due to this.

Find Ben Donatelli's comments in that thread, he steps you through the Frontend profile setup.
This takes ~17mins first time for my project and creates these files at the end. Leave the log open or save it. If you don't have these 6, open the log and ctrl+f for file_packager.py. If it looks like it logged a "wrong params, here's proper usage", then clean the Frontend project in Visual Studio, check you made the proper string changes, and then rebuild Frontend):
Tanky.data
Tanky.data.js
Tanky.html
UE4Game.bc
UE4Game.js
UE4Game.js.mem
(these 3 UE4Game files don't appear to be rebuilt rerunning the build process so later builds are faster)

Minor cleanup, open the html file in notepad or such, find the first script reference and add var tstart = Date.now();

Now open the data.js file. You're looking for the references to your .data file. They probably have a file/folder path structure in front that causes an error, you can strip that out so it just reads something like
var PACKAGE_NAME = 'Tanky.data';
datafile_Tanky.data
etc

You can try it out (and it'll crash and load really slowly) here http://www.quiet.net.nz/content/html5/tanky.html

Thursday, June 19, 2014

Tanky demo

http://quiet.net.nz/Home/Tanky
If you get "MSVCP120dll is missing", you'll need the redist pack from here (as found at
https://answers.unrealengine.com/questions/14088/msvcp120dll-is-missing-from-your-computer.html )

Slowly working on the style and the UI.
Find and kill the transport and the enemy base.
Weapons do different damage, you can't fly too high or your engines cut out.
Whether you win or lose, the game will reset after 10 seconds.

I've tried to keep to a colour scheme and a style of older games, so the UE4 settings are set to low or medium at best to achieve that, and left handed keybinds are also in thanks to my friend dm, full rebinding is later.

It's only spawning a single transport at the moment, but that is configurable for "missions". While the landscape hills are random, the spawn points are currently fixed. There is also a repair trigger that will be added once I do proper spawn placing.

Next up, some multiplayer I think.

Wednesday, June 4, 2014

Tanky

Been plugging away at this for some time, alternating between rank and file Warhammer Empire painting.

I'm solidly impressed with Unreal Engine 4. I've made a game framework with zero code only using their Blueprints system.
Here's the earliest generally working version:


Followed by the new models, projectiles:

Finally I added in an enemy base responsible for coordinating and spawning AI (complete with shields and hitpoints and effects), a spawn for enemy resupply and escorts...

Damage, enemy win conditions, level reloading and now I'm on to UI stuff, starting with a pause menu and now the inventory screen.

Still a fair bit to go but it's shaping up nicely. Once I get more inventory/damage types I'll go and start testing multiplayer (the core player ships already work nicely in MP).

I've learnt a fair bit about the landscape tools but I'm not 100% sure how I'll handle the terrain.