Scripts

Content and general development discussion, including quest scripts and server code. TMW Classic is a project comprising the Legacy tmwAthena server & the designated improved engine server based on evolHercules.


Forum rules

This forum houses many years of development, tracing back to some of the earliest posts that exist on the board.

Its current use is for the continued development of the server and game it has always served: TMW Classic.

Post Reply
User avatar
KaTSuo
Novice
Novice
Posts: 53
Joined: 25 Sep 2005, 19:01
Location: France
Contact:

Scripts

Post by KaTSuo »

Hi !

I just wanted to know if the new tmwserv have a different script language ? Npcs will have to be recoded ?

Regards,
KaTSuo
I'm French, sorry for my bad english XD !
Image
User avatar
Crush
TMW Adviser
TMW Adviser
Posts: 8046
Joined: 25 Aug 2005, 16:08
Location: Germany

Post by Crush »

Silene just added support for the Lua scripting language and created some basic NPC functions. Maybe we will implement other scripting languages too, but the eathena scripting language will most likely be none of them.

That means yes, all NPCs and other scripts will have to be rewritten for TMWServ.

Here is the current test script to give you an idea how the lua scripts for tmw will look: http://themanaworld.svn.sourceforge.net ... iew=markup
  • former Manasource Programmer
  • former TMW Pixel artist
  • NOT a game master

Please do not send me any inquiries regarding player accounts on TMW.


You might have heard a certain rumor about me. This rumor is completely false. You might also have heard the other rumor about me. This rumor is 100% accurate.
User avatar
KaTSuo
Novice
Novice
Posts: 53
Joined: 25 Sep 2005, 19:01
Location: France
Contact:

Post by KaTSuo »

Wow ! Looks pretty hard..

What about shops ? Is there any kind of function like eathena or do you have to script the whole shop ?

I hope your new language will be more complete than eathena scripts.

Good luck ;)
I'm French, sorry for my bad english XD !
Image
User avatar
Bjørn
Manasource
Manasource
Posts: 1438
Joined: 09 Dec 2004, 18:50
Location: North Rhine-Westphalia, Germany
Contact:

Post by Bjørn »

KaTSuo wrote:What about shops ? Is there any kind of function like eathena or do you have to script the whole shop ?

I hope your new language will be more complete than eathena scripts.
There is a function to do a shop, see the calls to tmw.npc_trade in the file Crush linked to.

Once you understand the structure of the script, it's actually not so hard. However, it would be nice if we could still get rid of some of the parameters that have to be passed around. At least the scripting language we use (Lua) is a lot more complete than eAthena's scripting language.
User avatar
Crush
TMW Adviser
TMW Adviser
Posts: 8046
Joined: 25 Aug 2005, 16:08
Location: Germany

Post by Crush »

Yes, Lua is a general purpose language and thus a lot more complex than the simple one-purpose scripting language of eAthena. This makes it not as easy and intuitive for server administrators without a programming background. But on the other hand using a common script interpreter gives us a lot of features that would take countless hours of work to integrate into a homebrewed scripting language.

String manipulation, scientific mathematics, reading and writing files, using external libraries... all stuff the eAthena scripting language can't.
  • former Manasource Programmer
  • former TMW Pixel artist
  • NOT a game master

Please do not send me any inquiries regarding player accounts on TMW.


You might have heard a certain rumor about me. This rumor is completely false. You might also have heard the other rumor about me. This rumor is 100% accurate.
Post Reply