Recent

Author Topic: Using Lua 5.4 with Free Pascal  (Read 623 times)

imekon

  • New Member
  • *
  • Posts: 17
Using Lua 5.4 with Free Pascal
« on: September 08, 2024, 12:54:28 pm »
Put together a sample of Lua integration with Free Pascal here:

https://github.com/imekon/luatest2

It's based on Lua54 for Pascal here: https://github.com/malcome/Lua4Lazarus

Currently released 32 bit versions but tried 64 bit with Lazarus just fine.

I'm using Lua with Raylib to put together a simple dungeon game, Lua is supplying the configuration script on startup.  :)

axel18

  • Newbie
  • Posts: 4
Re: Using Lua 5.4 with Free Pascal
« Reply #1 on: September 08, 2024, 07:34:15 pm »
why don t you  use raylib with pascal lazarius, you have a good binding with it ?
 

imekon

  • New Member
  • *
  • Posts: 17
Re: Using Lua 5.4 with Free Pascal
« Reply #2 on: September 08, 2024, 10:27:03 pm »
I'm using raylib with lazarus, but lua without lazarus

Roland57

  • Sr. Member
  • ****
  • Posts: 450
    • msegui.net
Re: Using Lua 5.4 with Free Pascal
« Reply #3 on: September 09, 2024, 05:14:59 am »
@imekon

Interesting. Thank you for sharing.

Here (Linux Mageia), I had to make the following change in lua54.pas.

Code: Pascal  [Select][+][-]
  1. {
  2.    LUA_LIB_NAME = 'liblua54.so';
  3. }
  4.    LUA_LIB_NAME = 'liblua-5.4.so';
My projects are on Gitlab and on Codeberg.

Weiss

  • Full Member
  • ***
  • Posts: 171
Re: Using Lua 5.4 with Free Pascal
« Reply #4 on: September 30, 2024, 07:00:10 am »
Pete (Pete?)

thank you for sharing. I am currently playing with Lazarus-Lua53, literally tried for the first time today. Thus, I have no knowledge about Lua whatsoever. Big question: how do I pass values from main application to embedded Lua interpreter? I am currently talking to Lua through text input in memo (TMemo). I am sure this must be something trivial, also sure I will eventually find it on my own, but quick pointers will be highly appreciated.

 

TinyPortal © 2005-2018