My first Engine modification. Blueprint Lock Node feature

Big Thanks to Rama for his extremely helpful wiki guide. For all those who wants to try out C++ I highly recommend following this guide: A new, community-hosted Unreal Engine Wiki - Announcements - Unreal Engine Forums

Am pretty excited today because I modified Engine source to add a feature I wanted. Its called Blueprint Lock Node feature. Basically what it does is, prevents the user from accidentally deleting any nodes. :slight_smile:

Commit Link: https://github.com/EpicGames/UnrealEngine/commit/c98c6ea9f7af5f419767e76cd33081fd848b2e8b

Toggles lock mode via context menu

And you will see a Notification saying node is locked…

…so you cant delete it :slight_smile:

If you want to delete that node then simply click on Toggle Lock again

This feature works for multiple nodes too :slight_smile:

That’s really great work Ryan Jon!

See! I always knew you’d be really good at C++!

Rock on!

:heart:

Rama

Awesome! just needs an icon on the node now :slight_smile:

Exactly. Am trying to figure out how to do that.

EDIT: Done. Locked nodes will now show icon :smiley:

Does the locked status save too or is it just per-session?
That would be handy when distributing Blueprint based content to other people to prevent them deleting important nodes accidently.

Nice one, I like this :slight_smile:

Sweet feature, get that pull request going!

Yes Kris! It saves with project :D. Actually that screenshot above your post is from re-opening the editor after compiling with that padlock icon.

Thanks CloDel Studios. :slight_smile:

Am not sure how to do that actually :rolleyes:. Trying to figure that out so thats why i didnt put the source here.

Easy, from your local clone of epic/master (you have one right?) make a branch: git checkout -b master_bp_lock_pr then make your BP lock node changes to files in this branch and commit them. Push this branch upstream to your github then run PR against epic/master from that new upstream branch.

Grab Git Bash from here Git - Downloading Package and install it in the context menu so you can right click inside any folder to open up a shell.

What?

You don’t use command line? Geez Louise!

Then you need to setup VS for this but to me it seems like a long winding process. In command line this would take all 3-4 lines to complete. Easy!

I saw your PR on github but I’m just confused as to what was the source, it says unknown repository? Also, I do not see your committed changes either.

Here’s how I did all of my Linux PRs (ie. https://github.com/3dluvr/unrealengine/tree/master_pr_for_epic_016 ):

  1. clone epic/master from github to my computer using terminal (since I was coding in Linux)
  2. locally branch off epic/master that I cloned above to a new branch 3dluvr/master_pr_for_epic_xx
  3. make changes to files in 3dluvr/master_pr_for_epic_xx and commit them
  4. push 3dluvr/master_pr_for_epic_xx up to my github repo
  5. using a web browser run a PR (green icon next to the branch name on github.com) against epic/master from my 3dluvr/master_pr_for_epic_xx directly that I pushed previously
  6. bug the hell out of epic|rcl on the IRC to merge my PR (optional)

This way the only changes showing would be the ones I made and not any of the commits Epic devs made. It makes it easier for them to merge the PR and reduces clutter.

Actually that was for updating my fork. :slight_smile:

So i selected promoted branch and clicked that green PR button and selected compare across forks. Now am here in this page. Should i just click Create pull request?

&stc=1

Yes that’s the process, although I would not use epic/promoted - that is the internal branch their artists and designers use.

Instead use epic/master, being the bleeding edge code, you are most likely to get your PR accepted. Epic can backport the code to lower branches from master if they want to.

Thank you buddy! :smiley:

Pull Request done: https://github.com/EpicGames/UnrealEngine/pull/739

You cheated :wink: I see ryanjon2040/promoted against epic/master, that’s why you have so many extra commits and it’s really not the right way of doing it.

As I said above, promoted is a derivative of master but using it for PRs is not really advisable as it gets things from upstream (master) not vice versa.

You do want Epic to accept your PR, right? Gotta make it easy for them to do so and presently they need to do figure out your changes from the rest.

haha not really :D.

I’ve never worked with master branch since 4.1 or so (last time i tried it failed to compile) and i made these changes from the promoted build.

Hehe, well I told ya they’d ask for epic/master rebase… :stuck_out_tongue:

lol no problem :wink:

So i have to download master and make the changes and make a new pull request?

Done. :cool:

Here it is: https://github.com/EpicGames/UnrealEngine/pull/745