Announcement

Collapse
No announcement yet.

Lua Blueprint Extension

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

    [PLUGIN] Lua Blueprint Extension

    Well, the first version of my Lua BP Extension is done.
    There are three ways to use this plugin.

    1. Basic setup with one single node. They can pass up to three arguments and return values but can only take strings [Run Lua Static String] or floats. [Run Lua Static Numeric]
    A simple example is shown below.

    Click image for larger version

Name:	1 - Simple Lua Setup.png
Views:	1
Size:	58.0 KB
ID:	1158469



    2. The extended setup can be created with the [Run Lua Static] node.
    This node takes and returns an array of [LuaValue] wich can contain a String, Float, Boolean, String Array or Float Array.
    There are different conversion nodes available for each type.

    Click image for larger version

Name:	2 - Simple Lua Setup with mixed args.png
Views:	1
Size:	89.5 KB
ID:	1158470


    3. The advanced setup allows the code to be precompiled before it is executed. In addition to that it gives you the possibility to register custom Blueprint functions wich can be called from Lua code.

    Click image for larger version

Name:	3 - Advanced Lua Setup.png
Views:	1
Size:	209.1 KB
ID:	1158471


    A Blueprint function can look like this. Values can only be returned by calling the [Return] or [ReturnSingleValue] node! The difference between them should be obvious.

    Click image for larger version

Name:	4 - Advanced Lua Setup Subfunc.png
Views:	1
Size:	100.2 KB
ID:	1158472


    Notes:
    • The interpreter calls the Main(arg1, arg2, ..) function with the given arguments in order. The name of arguments is not relevant!
    • Code that is not enclosed within any function will be executed immediatly after the code is loaded! This might be useful for some initialization but should still be avoided.
    • This plugin uses Lua 5.3.0. Be aware that some older Lua examples you find on the internet might not work. This is NOT a Bug!
    • Check the Message Log window. The Plugin tells you if there's something wrong with the your Lua code.


    Other than bugfixes I'm not planning to develop this plugin any further without request from the community.
    So please post suggestions, Bugs or just usage experiences.

    Download: https://www.dropbox.com/sh/9jm9lkv4j...2Qg2yfwOa?dl=0


    Cheers

    ( And yes, I'm to lazy for a serious documentation :3 )



    Update to 0.5.1:
    Bugfix: Lua Nodes in some Blueprint classes fail to load after Plugin recompilation.

    Update to 0.5.2:
    Now compatible with 4.9.0 P2
    Last edited by Noxygen; 08-06-2015, 03:27 AM.

    #2
    Very cool
    Broad Strokes | Jan Kaluza | Marketplace Release: 'Over 9000 Swords' Modular Melee Weapon System
    Currently not available for freelance work
    Dev Blog & Tutorials | Twitter

    Comment


      #3
      thank you

      Comment


        #4
        Nice job!!!!

        Comment


          #5
          This is really awesome!
          2B || (!2B)

          Comment


            #6
            (Update to 0.5.2)

            Comment


              #7
              Scripting within scripting!

              Comment


                #8
                Scripting within scripting!
                Multi layers = slower

                Epic will bring official C# at some point as majority of 3D engines have some easy to use scripting language.

                Comment


                  #9
                  Originally posted by Galeon View Post
                  Multi layers = slower

                  Epic will bring official C# at some point as majority of 3D engines have some easy to use scripting language.
                  I doubt Epic will bring C# as it would hurt the game's cross platform support. C# isn't well supported on Linux or Mobile.
                  CrashGame (Working title for my survival/exploration game) - YouTube

                  Comment


                    #10
                    I doubt Epic will bring C# as it would hurt the game's cross platform support. C# isn't well supported on Linux or Mobile.
                    I didn't consider mobile when i was talking about C# integration as Unreal 4 is in primarily an advanced AAA 3D engine for PC and consoles.

                    Comment


                      #11
                      How do I press "Enter" at the end of each line in the text boxes in the "Run Lua" nodes?

                      Comment


                        #12
                        Hold shift down while pressing Enter.
                        But it's better to write your code in a Notepad of your choice (I recommend Notepad++) and copy&paste it. Sadly there is no better way yet.

                        Comment


                          #13
                          That's amazing, great work!

                          Comment


                            #14
                            In there any version of this great plugin compatible with UE 4.12?

                            Comment


                              #15
                              Originally posted by LeoBos67 View Post
                              In there any version of this great plugin compatible with UE 4.12?
                              Is this compatible with you UE4 4.14. I would love to use this LUA Plugin to create/modify script during runtime using in-game text editor (UMG). EXCELLENT WORK.
                              ExORION Sci-Fi Action/Terror FPS needs 3D KitBashers and Blueprinters. Join Our Discord.

                              Comment

                              Working...
                              X