Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to reposition and modify ui elements in more detail #53

Open
wants to merge 16 commits into
base: master
Choose a base branch
from

Conversation

YawLighthouse
Copy link

@YawLighthouse YawLighthouse commented May 24, 2019

Hello I've been working on the loading screen plugin for my own game and have been adding to it, and thought it would be good to share it with everybody! So Im submitting this pull request for a ton of features that allow for more control over this plugin.

  • Ability to re-position ui elements (its based off a canvas being the root essentially so all you need to do is make a Widget Blueprint and place widgets on the canvas like you normally would and just copy their slot values into the loading screen settings)
  • Ability to toggle visibility on each widget object ahead of time(cause not everybody would want tips on a specific kind of loading screen)
  • Ability to modify the text's font, size, color and opacity, AND MORE! :D
  • Ability to have ui elements play during or after movies play(this also works the same way with images)
  • Separated aspects of each element into their own structures on the C++ side to make it easier to modify and add to and
  • Ability to have a delay between tips before it automatically updates to a new random one(if you just want one to show up per loading screen I already took care of that functionality for you ;) )

I think thats about it I spent a good chunk of time basically reworking it to be more modifiable, let me know what you think if you or if you found any problems with it, I just wanna make this plugin as useful as possible. :)

(Sorry if the commit list for this is a little vague, was doing minor changes that I forgot to add until the last minute)

@lucastucious
Copy link

Your update make my UE 4.22.1 project crash at startup :(

@YawLighthouse
Copy link
Author

@LucasDLK ok, I have 2 things to ask, is it possible I could get an error from you (so I can find out where it crashed and fix it)? And I tested it on the launcher version of 4.22.2 and the source version, maybe try updating and see what happens?

Fixed crash where slate application was not valid on startup, replaced it with FPlatformTime.
@YawLighthouse
Copy link
Author

@LucasDLK K try now, if it crashes again please give me the error code :)

Constant for a boolean that isnt getting changed anywhere else
@Zod20
Copy link

Zod20 commented May 25, 2019

@Oldsiren works for me and its awesome! Can you tell me how to do 'wait for manual stop'? I can't seem to find a blueprint node to call from within my code to stop it.

@YawLighthouse
Copy link
Author

@Zod20 Manual stop only gets used when Stop Movie is called(which because its during a loading screen its not really possible to run any blueprint code during that time) and when a any key is pressed(which is used by the MoviesAreSkippable boolean and only works if its actually finished loading and if that boolean is true) if you want a movie to stop playing when it finishes loading, then set AutoCompleteWhenLoadingCompletes to true. Honestly I dont think Wait for manual stop is actually useful for this plugin or even used but I kept it in because maybe in the future it will be.

@lucastucious
Copy link

lucastucious commented May 27, 2019

Ok, i've updated my project to 4.22.2, still crash at startup. Here is the error :

Assertion failed: IsValid() [File:c:\program files\epic games\ue_4.22\engine\source\runtime\core\public\Templates/SharedPointer.h] [Line: 797] UE4Editor_LoadingScreen!SSimpleLoadingScreen::Construct() [f:\unrealprojects\altexp\altexp_ue4\plugins\loadingscreen-master\source\loadingscreen\private\ssimpleloadingscreen.cpp:166] UE4Editor_LoadingScreen!FLoadingScreenModule::BeginLoadingScreen() [f:\unrealprojects\altexp\altexp_ue4\plugins\loadingscreen-master\source\loadingscreen\private\loadingscreenmodule.cpp:122] UE4Editor_LoadingScreen!FLoadingScreenModule::StartupModule() [f:\unrealprojects\altexp\altexp_ue4\plugins\loadingscreen-master\source\loadingscreen\private\loadingscreenmodule.cpp:65]

Here is a link to full error log :
EDITED : an error file generated with empty C++ project
https://pastebin.com/FKCSnKZ6

Fixed crash from tooltips not having any to display. Where the widget was not created when it should have been
@YawLighthouse
Copy link
Author

@LucasDLK ok I found the bug, it was related to the tooltips. It should be good to go now, let me know if it works :)

@lucastucious
Copy link

lucastucious commented May 28, 2019

It seems that your update work ! Thank you

An image(or material) can be used in place of a throbber
@lucastucious
Copy link

Can you make an option to randomize tips ?

@YawLighthouse
Copy link
Author

@LucasDLK it does randomize tips automatically, if you want it to randomize it while loading the mouse has to be moving in the app(currently trying to figure out how to fix it so it works regardless of mouse movement)

@infinstarlight
Copy link

Hey there, I'm trying to set the position of the text but I'm having a hard time getting it in the right place. Is there any way to see the widget locations without having to start a standalone process?

@YawLighthouse
Copy link
Author

@professionaljones at the moment my solution is to just make an empty widget blueprint and plan out the placement there with a canvas panel being the root(because thats what Im using in this branch of the plugin) and then just copy those values over into the plugin's settings

@Byrkoet
Copy link

Byrkoet commented Jun 21, 2019

Setting tips and changing MinimumLoadingScreenDisplayTime from -1.000 to anything above 0 causes the widget to hang and only hide/collapse when input is detected :/

@YawLighthouse
Copy link
Author

@Byrkoet so thats something with the ue4 loading screen system, basically this plugin talks with stuff thats already in the engine that handles the loading screen and one of those in engine settings is the MinimumLoadingScreenDisplayTime variable. Unless @nickdarnell would be able to provide a better answer or solution to what ever your trying to do, I'm not going to be of much help... (btw Nick thank you for the plugin, from one Nick to another ;) )

@DW-Sebastien
Copy link

@Oldsiren this looks very promising, thanks for sharing!

I will try to update to your version in the process of upgrading our project to Unreal Engine 4.22 (should happen in the coming days)

In the meantime, I would suggest you rename this Pull Request with a clear title, stating what it does to all the people looking at this :)

@YawLighthouse YawLighthouse changed the title Super Duper Update Ability to reposition and modify ui elements in more detail Jun 26, 2019
Just an ease of use thing that fixes any warning or issues where it cannot find the public/private include paths when compiling from source.
Fixed system.io library not being included, formatted file to be with the way build files for unreal are currently formatted and setup
@ghost
Copy link

ghost commented Aug 24, 2019

Hi! First of all I must say that this plugin, and then this branch are incredibly awesome. I had my own loading screen WBP until now, and this is just heaven because you don't have to do anything. Although, I have 2 questions:

  1. For some reason, the center justification doesn't work at all on my text. Could it be an issue on my end?
  2. I know this is not the intended use, but sometimes you might want to show loading screens before level travels. (Creating lobbies, loading data, etc.) Do you think there could be a way to show this loading screen at will with either C++ or Blueprints? I would just keep my current loading screen WBP, but the transition between them is not that pleasant.
    Thank you!

@YawLighthouse
Copy link
Author

@SIBarbu Hello! Sorry for not getting back to you sooner... been dealing with work related stuff that threw my whole financial situation out of wack. Anyway the text justification does work, I recommend opening up an empty widget blueprint with just a canvas and text block because that's basically how the layout of the loading screen is setup. Also for being able to start showing the loading screen outside of level travels, I will look into setting that up but it will take some time, Im also going to add the ability to be able to modify the default loading screen as well.... I'm probably gonna be adding in a function library or something similar to handle these things :)

@ghost
Copy link

ghost commented Aug 27, 2019

@Oldsiren Oh, I am sorry to hear that. I hope you will manage to fix your situation. Just take your time and I am going to wait patiently hehe.

@avfxproton
Copy link

Hi Oldsiren,

I have two feature requests, and then I think your branch would be perfect.

1, Ability to fade in and fade out the loading screen on begin and end.
2, Ability to trigger the loading screen via blueprint not only when opening levels, but when doing some more complex level streaming, and then end the loading screen via blueprint aswell.
3, The third is not really a feature request, but rather a question. The startup loading screen takes 3-4 seconds even on a blank startup level. Is there some artificial timer for this? And is there a way how to turn off this behavior?

I would take a swing at adding these features myself, but then I would not want to merge my changes with each new updates, and if u decided to do it anyway, I think you would code it much differently than I would.

Thanks a lot for your great work!

@YawLighthouse
Copy link
Author

Hello @avfxproton,

So those feature requests are out of scope for what this plugin is meant to be(at that point I would suggest taking a look at the Action RPG's Loading Screen module as it has those features your looking for).
Also to answer your question about the 3-4 seconds, it is an artificial timer within the loading screen module inside the engine(to modify that you would do this in the project settings for the loading screen plugin). If its still doing this please let me know about the steps to reproduce it on my end and I should be able to fix it when I have time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants