Scripting in FPC

classic Classic list List threaded Threaded
35 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Scripting in FPC

Bugzilla from elio@mixtk.com
Hi.

I want to embed an interpreter in my Free fpc game to provide an scripting
interface. What are the available solutions? I have heard about Nemesis
Pascal but i'm not sure if it works in FPC as it's website talks only about
Delphi and Kylix.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Alain Michaud
HI,

FPC is compiled only

Alain

On Wed, 2006-02-08 at 19:39 -0600, Elio Cuevas Gómez wrote:
> Hi.
>
> I want to embed an interpreter in my Free fpc game to provide an scripting
> interface. What are the available solutions? I have heard about Nemesis
> Pascal but i'm not sure if it works in FPC as it's website talks only about
> Delphi and Kylix.
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
L-9
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

L-9
> HI,
>
> FPC is compiled only
>
> Alain


There are some scripting systems out there, RemObjects which I think Boguslaw was
working on completing the latest version? There is another one that I think costs
money, and maybe a few on TOrry.net which could be converted from Delphi to FPC.


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Felipe Monteiro de Carvalho
In reply to this post by Bugzilla from elio@mixtk.com
I would probably try to use Pascal Script. It seams really good. I've
never heard of nemesis so I can't really compare, it might be good
also.

You can find more information about Pascal Script here:

http://wiki.lazarus.freepascal.org/index.php/Pascal_Script

and here:

http://www.remobjects.com/articles/?id={2FFC1EE9-F18D-4B11-9DE4-1BA0A79D0D04}

--
Felipe Monteiro de Carvalho
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Bugzilla from elio@mixtk.com
It looks very good, but i would preffer to avoid the use of Lazarus (Not that
Laz is bad, i love it, but i want to keep the program small, with few
dependencies). Also i think the Licence is GPL incompatible, which is very
unfortunate :-(.

El Mié 08 Feb 2006 20:49, Felipe Monteiro de Carvalho escribió:

> I would probably try to use Pascal Script. It seams really good. I've
> never heard of nemesis so I can't really compare, it might be good
> also.
>
> You can find more information about Pascal Script here:
>
> http://wiki.lazarus.freepascal.org/index.php/Pascal_Script
>
> and here:
>
> http://www.remobjects.com/articles/?id={2FFC1EE9-F18D-4B11-9DE4-1BA0A79D0D0
>4}
>
> --
> Felipe Monteiro de Carvalho
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Bugzilla from elio@mixtk.com
In reply to this post by L-9
I found this one in the web:
https://opensvn.csie.org/PascalScript/
Seems very good, but it will need some work, the Virtual Machine is
embedabble, but looks like the compier is a separated program.

El Mié 08 Feb 2006 20:04, L escribió:

> > HI,
> >
> > FPC is compiled only
> >
> > Alain
>
> There are some scripting systems out there, RemObjects which I think
> Boguslaw was working on completing the latest version? There is another one
> that I think costs money, and maybe a few on TOrry.net which could be
> converted from Delphi to FPC.
>
>
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Jeff Pohlmeyer
In reply to this post by Bugzilla from elio@mixtk.com
> I want to embed an interpreter in my Free fpc game...

How about LUA ?
http://www.lua.org/about.html

FreePascal bindings:
http://assoc.wanadoo.fr/thallium-software/thlua.en.html


- Jeff
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Michael Van Canneyt
In reply to this post by Bugzilla from elio@mixtk.com


On Wed, 8 Feb 2006, Elio Cuevas Gómez wrote:

> It looks very good, but i would preffer to avoid the use of Lazarus (Not that
> Laz is bad, i love it, but i want to keep the program small, with few
> dependencies). Also i think the Licence is GPL incompatible, which is very
> unfortunate :-(.

1. The license is not GPL incompatible ?
2. You don't need lazarus, only if you want to do GUI.

I use Pascalscript since years, and it works very well.

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Marco van de Voort
In reply to this post by Bugzilla from elio@mixtk.com
> I want to embed an interpreter in my Free fpc game to provide an scripting
> interface. What are the available solutions? I have heard about Nemesis
> Pascal but i'm not sure if it works in FPC as it's website talks only about
> Delphi and Kylix.

There is remobjects' passcript too. It has compiled with FPC before.

Usually Delphi code is portable to fpc, so that doesn't have to be that big
a barrier.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Kornel Kisielewicz
In reply to this post by Bugzilla from elio@mixtk.com
Elio Cuevas Gómez napisał(a):
> Hi.
>
> I want to embed an interpreter in my Free fpc game to provide an scripting
> interface. What are the available solutions? I have heard about Nemesis
> Pascal but i'm not sure if it works in FPC as it's website talks only about
> Delphi and Kylix.

As I understand you're asking about scripting languages in general, not
only Pascal-syntax languages -- in that case I recommend Lua -- it's
realy fast (one of the fastest scripting languages in it's class), it's
easy to set up and realy easy to learn.
--
At your service,
Kornel Kisielewicz (adminATchaosforge.org) [http://chaosforge.org]
"Oh come on. We both know the truth about this game --
vapourware." -- Anathiel about GenRogue
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Matt Emson
In reply to this post by Bugzilla from elio@mixtk.com

Nemesis relies heavily on the JVCL and the Scripting engine that is
contained within it. Unfortunately, this engine uses Interfaces heavily,
and FPC had issues with Interfaces last time the dev looked at a port.

FPC2.0x or maybe CVS build might be okay. Dunno though, one of the
developers of FPC might like to comment on the status if IInterface,
IUnknown and TInterfacedObject etc... IIRC there were serious reference
counting issues at one point, but that was some time ago now.

> I want to embed an interpreter in my Free fpc game to provide an scripting
> interface. What are the available solutions? I have heard about Nemesis
> Pascal but i'm not sure if it works in FPC as it's website talks only
> about Delphi and Kylix.


_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Re: Scripting in FPC

Bugzilla from elio@mixtk.com
In reply to this post by Jeff Pohlmeyer
El Mié 08 Feb 2006 22:18, Jeff Pohlmeyer escribió:
> > I want to embed an interpreter in my Free fpc game...
>
> How about LUA ?
> http://www.lua.org/about.html
>
> FreePascal bindings:
> http://assoc.wanadoo.fr/thallium-software/thlua.en.html
>

Yes! It seems like i was looking for, thank you very much :-)

>
> - Jeff
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Bugzilla from elio@mixtk.com
In reply to this post by Kornel Kisielewicz
El Jue 09 Feb 2006 04:00, Kornel Kisielewicz escribió:
> As I understand you're asking about scripting languages in general, not
> only Pascal-syntax languages -- in that case I recommend Lua -- it's
> realy fast (one of the fastest scripting languages in it's class), it's
> easy to set up and realy easy to learn.

That's correct. Pascal-like syntax would be nice, but is not required. I took
a look at Lua and it seems like it would work. I miss the strict typing of
Pascal but i can live without it :-)
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Bugzilla from elio@mixtk.com
In reply to this post by Michael Van Canneyt
El Jue 09 Feb 2006 02:10, Michael Van Canneyt escribió:
> On Wed, 8 Feb 2006, Elio Cuevas Gómez wrote:
> > It looks very good, but i would preffer to avoid the use of Lazarus (Not
> > that Laz is bad, i love it, but i want to keep the program small, with
> > few dependencies). Also i think the Licence is GPL incompatible, which is
> > very unfortunate :-(.
>
> 1. The license is not GPL incompatible ?

I'm not a lawyer, but clause 3 of the license requires you to advertise
RemObjects Pascal Script, which renders the license GPL incompatible. Of
course i might be wrong, as i said IANAL.

> 2. You don't need lazarus, only if you want to do GUI.

I'm doing the GUI in SDL, but i still need the LCL to be able to use Pascal
Script, right?

>
> I use Pascalscript since years, and it works very well.
>
> Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Michael Van Canneyt


On Thu, 9 Feb 2006, Elio Cuevas Gómez wrote:

> El Jue 09 Feb 2006 02:10, Michael Van Canneyt escribió:
> > On Wed, 8 Feb 2006, Elio Cuevas Gómez wrote:
> > > It looks very good, but i would preffer to avoid the use of Lazarus (Not
> > > that Laz is bad, i love it, but i want to keep the program small, with
> > > few dependencies). Also i think the Licence is GPL incompatible, which is
> > > very unfortunate :-(.
> >
> > 1. The license is not GPL incompatible ?
>
> I'm not a lawyer, but clause 3 of the license requires you to advertise
> RemObjects Pascal Script, which renders the license GPL incompatible. Of
> course i might be wrong, as i said IANAL.

What does 'advertise' mean in this context ?

> > 2. You don't need lazarus, only if you want to do GUI.
>
> I'm doing the GUI in SDL, but i still need the LCL to be able to use Pascal
> Script, right?

No; FPC is enough.

Michael.

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Bugzilla from elio@mixtk.com
El Jue 09 Feb 2006 14:13, Michael Van Canneyt escribió:
> What does 'advertise' mean in this context ?

3. You must have a visible line in your programs aboutbox or
   documentation that it is made using RemObjects Pascal Script and
   where RemObjects Pascal Script can be found.

i. e. You must put a link to RO homepage in your about box or your readme.
Since i won't have an about box then the choice left is to put it in the
readme, not a big deal since i do that sort of thing anyway, but is
GPL-Incompatible nevertheless.

> > I'm doing the GUI in SDL, but i still need the LCL to be able to use
> > Pascal Script, right?
>
> No; FPC is enough.

I guess i haven't gave PascalScript a fair view, i'll have a look later.

>
> Michael.
>
> _______________________________________________
> fpc-pascal maillist  -  [hidden email]
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Jeff Pohlmeyer
In reply to this post by Bugzilla from elio@mixtk.com
> > How about LUA ?

> Yes! It seems like i was looking for, thank you very much :-)

Glad to help!

There is also an IDE for LUA, written in Delphi:

http://luaedit.luaforge.net/

It is probably overkill for what you need, but it might
be useful to get some ideas on pascal+lua integration.


 - Jeff
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Michael Van Canneyt
In reply to this post by Bugzilla from elio@mixtk.com


On Thu, 9 Feb 2006, Elio Cuevas Gómez wrote:

> El Jue 09 Feb 2006 14:13, Michael Van Canneyt escribió:
> > What does 'advertise' mean in this context ?
>
> 3. You must have a visible line in your programs aboutbox or
>    documentation that it is made using RemObjects Pascal Script and
>    where RemObjects Pascal Script can be found.
>
> i. e. You must put a link to RO homepage in your about box or your readme.
> Since i won't have an about box then the choice left is to put it in the
> readme, not a big deal since i do that sort of thing anyway, but is
> GPL-Incompatible nevertheless.

I don't see how this is incompatible, as I have no recollection of
a clause in the GPL that says that you should not credit parts of the system... ?

But never mind, that's probably me being stubborn ;-)

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

L505
> > What does 'advertise' mean in this context ?
>
> 3. You must have a visible line in your programs aboutbox or
>    documentation that it is made using RemObjects Pascal Script and
>    where RemObjects Pascal Script can be found.
>
> i. e. You must put a link to RO homepage in your about box or your readme.
> Since i won't have an about box then the choice left is to put it in the
> readme, not a big deal since i do that sort of thing anyway, but is
> GPL-Incompatible nevertheless.

> > I don't see how this is incompatible, as I have no recollection of
> > a clause in the GPL that says that you should not credit parts of the system... ?
> >
> > But never mind, that's probably me being stubborn ;-)
> >
> > Michael.

Take a look at Stallman's page about FreeBSD license and how freebsd "advertises
Berkley and California unreasonably" or whatever. Personally I'm more of a FreeBSD
style guy and I might even switch to FreeBSD over linux because of religion.

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: Scripting in FPC

Michael Van Canneyt


On Thu, 9 Feb 2006, L505 wrote:

>>> What does 'advertise' mean in this context ?
>>
>> 3. You must have a visible line in your programs aboutbox or
>>    documentation that it is made using RemObjects Pascal Script and
>>    where RemObjects Pascal Script can be found.
>>
>> i. e. You must put a link to RO homepage in your about box or your readme.
>> Since i won't have an about box then the choice left is to put it in the
>> readme, not a big deal since i do that sort of thing anyway, but is
>> GPL-Incompatible nevertheless.
>
>>> I don't see how this is incompatible, as I have no recollection of
>>> a clause in the GPL that says that you should not credit parts of the system... ?
>>>
>>> But never mind, that's probably me being stubborn ;-)
>>>
>>> Michael.
>
> Take a look at Stallman's page about FreeBSD license and how freebsd "advertises
> Berkley and California unreasonably" or whatever. Personally I'm more of a FreeBSD
> style guy and I might even switch to FreeBSD over linux because of religion.

That page is a load of b*s*, because the LGPL requires just the same:
your program must show the LGPL.

Nitpicking pure style. It's the spirit of the license that counts:
Free software must remain free, and you must give credit where it's due.

The rest is food for lawyers without work.

Michael.
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal
12