rdeioris/LuaMachine

Character's functions from state

Closed this issue · 6 comments

Hi, I am trying to call functions of a Character from a Widget run, I'm getting my Character from my Lua State but when I try to call Characters function, nothing happens, and nothing in my console..

In game:
image

Commands + when pressing run:
image

GetPlayer()
image

Player's Lua Component's Content
image

Hi @Nogitsu , thanks for the great report. Your issue is related to a non-updated docs paragraph about LuaComponent usage (just fixed it). In the latest releases i have removed any form of 'automagic' from the plugin, so when you return an Actor (even if it has a LuaComponent attached), the actor itself will be received by Lua (as userdata):

https://github.com/rdeioris/LuaMachine/blob/master/Docs/LuaComponent.md#luacomponent-interactions

This allows a more versatile approach for advanced extensions (like the reflection described here: https://github.com/rdeioris/LuaMachine/blob/master/Tutorials/ReflectionShell.md)

I have just released a new update including various shortcuts for retrieving the LuaComponent from an Actor as a LuaValue.

If you want to fix your blueprint without updating, just call GetComponentByClass after the GetPlayerPawn, and encapsulate the result in a lua value.

Let me know if it works for you

So, first, I've done like this
image
but it didn't worked (but no error in the console)
And then I've done this to see if the problem where from getting on pawn or by class
image
But still doesn't work..

And I'd like to update, but excluding the binaries, nothing works ^^'
I think that you should make a discord for LuaMachine ! It should be nice to talk there and share everybody's creations using it 😄

Hi again, the plugin has been approved for the Marketplace, so i need to check if i can make a binary release here. (older binary releases are pretty outdated)

Approved but not published ?
image

Yep, i am finalizing the last tutorial before publishing. By the way i have added a new binary release:

https://github.com/rdeioris/LuaMachine/releases/tag/20190131

as well as a discord channel: https://discord.gg/eTXDfEU

The binary release now works, thanks 😃