Jump to content

Noob LUA idea


Dan_Incognito
 Share

Recommended Posts

Hey guys sorry if this is a dumb idea but i just want to clear up an idea i had, ok so im new to lua and im wondering say i have an ai script from the cryengine sdk and i want to use the code in leadwerks can i do this? now i dont mean a direct copy and past obviously that wont work but is there a way to tweek the script to get it to work? Im learning lua but just want to see if i can get elements from some scripts to work so i can learn how they work. Anyway sorry again if this is dumb and thanks in advance for any help! :(

Games before Dames.

Link to comment
Share on other sites

Yeah, you can use any logic in LE. So just copy the logic, not the code, and it will work.

Copying logic works so that you first read and understand what the original code does, then you just transfer your knowledge by coding it in another engine.

Sounds logical, right?

Ryzen 9 RX 6800M ■ 16GB XF8 Windows 11 ■
Ultra ■ LE 2.53DWS 5.6  Reaper ■ C/C++ C# ■ Fortran 2008 ■ Story ■
■ Homepage: https://canardia.com ■

Link to comment
Share on other sites

No, logic is not computer based at all, it's all in your head. But you use your head to read the logic from one computer program, and then you implement the same logic to another computer program. As an example, if the CE script picks up an object when you press F, then you would know in you head that this happens when you press F, and then you can do the same in LE. Of course you need to know then also what commands you need for doing that logic in LE, but it's quite simple, basically just a EntityPick(player,3) (upto 3 meters away) when KeyHit(KEY_F) occurs, and then FreeEntity(object) and add it to your inventory as a simple text item.

Ryzen 9 RX 6800M ■ 16GB XF8 Windows 11 ■
Ultra ■ LE 2.53DWS 5.6  Reaper ■ C/C++ C# ■ Fortran 2008 ■ Story ■
■ Homepage: https://canardia.com ■

Link to comment
Share on other sites

Really what you would be looking for is just general AI tutorials and then use your knowledge of the Lua programming language to make those tutorials come to life inside Lua. Most every programming language has the pieces to make a "theory" of AI come to life via code.

Link to comment
Share on other sites

Thanks Rick :) I'll have a look around and get my head into it all :) Also just want to say thanks to everyone on the fourms, i know im pretty new and dont know it all yet but anytime iv asked a question in the fourms everyone has been very nice and helpful and i do really appreciate that so thanks everyone :) Its a plesure to be learning on the leadwerks fourms :)

Games before Dames.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...