I’ve been trying to get my game to a polished state to start showing off, but the more I work the more I keep hitting little oddities that I can’t seem to work around. Since I’m working in blueprint and I kind of have several different problems, I figured this would be the best place to ask.
(EDIT: It seems that Rama’s Victory plugin has some helper functions that allow you to write out variables to the Game.ini)
- Setting up .ini game settings (e.g. VSync, Full screen, screen resolution)
I’ve figured out a work around, basically parsing variables and generating console commands, but it seems just awful that the .ini file has settings that are read when the game is launched, then the game reads my saved data, and executes upon that. It seems like a really crucial oversight that you can’t read/write to the basic options file of your game, and instead have to use a work around that essentially is reading the .ini, launching the game with those settings, then reading my custom options, then adjusting again. Did I miss something crucial here? Not only does my method seems slow, it also conflicts with the .ini and can’t be manually changed by the player, but it seems to be the only way through blueprint.
- Basic sequences of events
I only really started seeing this recently, but it seems like blueprints don’t consistently execute in order. The ‘sequence’ node is a big pain for me, because it doesn’t actually do things sequentially. It’s pins fire off sequentially, but it doesn’t wait for one pin to complete it’s chain before the next, meaning if one pin takes even a little bit of time to execute, you need to manually force delays to ensure they execute in the correct order. This becomes even worse when you’re trying to time things together. For example, I have a ‘fade to black’ widget that I use to try and cover level loads, player resets, and other jarring transitions. The problem is that the ‘fade’ effect takes 1 second, but I usually have to delay for a solid 1.5 - 2 seconds before removing it or passing another fade (from black to transparent), otherwise the widget never finishes it’s transition or conflicts with the current effect.
That’s bad, but even worse, it seems that the game doesn’t wait for ‘begin play’ commands to execute before displaying the world, so when trying to fading from black to transparent upon a level load, 90% of the time you will see like 3-4 frames of fully visible level before it cuts to black and fades properly. It also seems to display the level before it’s properly loaded, with textures popping in and sometimes it seems even before it’s loaded lightmaps (popping the lighting needs to be rebuilt error onto the screen for a few frames).
I’m not sure if there’s a more reliable way to ensure everything happens in the right order, but it just seems that the engine doesn’t really care about when blueprint commands are supposed to fire, it’ll just get to them when it can.
- Hiding the mouse cursor doesn’t work without player input
This one isn’t that big of a problem, but it really makes the game feel a little unprofessional. Upon loading into the game, you hit a main menu, and the pawn runs the ‘show mouse cursor’ on the controller, showing the cursor and allowing you to use the menus. Everything good so far. However, upon clicking new game, it runs same thing except set to false and nothing happens; the cursor stays. Then after playing an animation, it loads the first level, a scene with a custom first person character with mouse look. I have tried setting it to run the same command as earlier on play, but still the cursor is there, and as long as the cursor is visible, mouse look doesn’t work. When you click, it refocuses on the viewport and suddenly the cursor goes away and mouse look starts working again. So it’s not exactly game breaking, but it seems really odd that you can show the cursor through commands, but there’s no way to hide it without additional input from the player. I did find this (Answerhub) but all the answers were basically recommending I do what I’ve already done or start using C++.
While this isn’t catastrophic for me, I could understand any game that has in game menus to find this kind of nightmarish. It’s also kind of making me reluctant to implement an in game pause menu, since it’s just going to cause this over and over.
Anyway, sorry for the long post. I would appreciate any solutions or work-around to anything here. I’m kind of frying my brain over this and beating my head against the wall.