Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 07-11-2008, 09:42 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
The "mudlib" obsession

  1. It seems that the average forum user/scripter on Graal has no real concept as to what a "mudlib" really is.
    Quote:
    Originally Posted by Wikipedia
    A mudlib is a library of interpreted code used to create a MUD. It is interpreted code usually written in the LPC language. The code is interpreted on the fly by a driver.
    Quote:
    Originally Posted by Wikipedia
    In computer gaming, a MUD (Multi-User Dungeon, Domain or Dimension) is a multi-player computer game that combines elements of role-playing games, hack and slash style computer games and social chat rooms.
    So, please can we stop using the term "mudlib" to describe your scripts?

  2. Can someone please explain to me what advantages a system that reads and writes from text files for all player or item data really has? I find it difficult to believe that, whatever it is, it justifies the:

    • More CPU cycles going to loss to read and write text files when the gserver is already doing this for Database NPC flags or player attributes;
    • Greater memory usage in caching both player flags and even more text data;
    • Files filling up file manager which are just going to turn into a disorganised mess;
    • More layers of scripting that could potentially go wrong and may need debugging, or more things to confuse someone else who has to work with your systems.
This GST doesn't approve.
Reply With Quote
  #2  
Old 07-11-2008, 09:47 PM
Tigairius Tigairius is offline
The Cat
Tigairius's Avatar
Join Date: Jan 2007
Location: Missouri, USA
Posts: 4,240
Tigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant futureTigairius has a brilliant future
I use clientr. strings for most of my item systems because I find that they're more efficient than loading from text files all the time, I normally frown upon the use of text databases unless they actually plan on having multiple characters, similar to how Zodiac allows you to select which character you'd like to use.
__________________


“Shoot for the moon. Even if you miss, you'll land among the stars.”
Reply With Quote
  #3  
Old 07-11-2008, 09:51 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
I find clientr strings extremely messy, and, given the RC bug which crops them to 256 characters, a mess waiting to happen.
Reply With Quote
  #4  
Old 07-11-2008, 09:52 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by DustyPorViva View Post
I find clientr strings extremely messy, and, given the RC bug which crops them to 256 characters, a mess waiting to happen.
It strikes me that you might be saving too much superfluous data, then.
Reply With Quote
  #5  
Old 07-11-2008, 09:54 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
It depends on what you want to save, honestly.
My system involved items having unique statistics, so it all had to be saved individually for each weapon.
Reply With Quote
  #6  
Old 07-11-2008, 09:55 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by DustyPorViva View Post
It depends on what you want to save, honestly.
My system involved items having unique statistics, so it all had to be saved individually for each weapon.
Well, even in that case, how were you saving each individual statistic? In strings like "str+1,dex+2"?
Reply With Quote
  #7  
Old 07-11-2008, 09:59 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Quote:
Originally Posted by Skyld View Post
Well, even in that case, how were you saving each individual statistic? In strings like "str+1,dex+2"?
No, I saved them just as numbers. I actually tried to keep it under 256 characters, but that doesn't account for future additions/long names, any other number of variables introduced by other staff. And anyways, when all done, all I had was a huge mess of numbers and quotes because graal turns {}'s into ""s, which is makes it even harder to read.
Reply With Quote
  #8  
Old 07-11-2008, 10:01 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by DustyPorViva View Post
No, I saved them just as numbers. I actually tried to keep it under 256 characters, but that doesn't account for future additions/long names, any other number of variables introduced by other staff. And anyways, when all done, all I had was a huge mess of numbers and quotes because graal turns {}'s into ""s, which is makes it even harder to read.
You could just use a single integer with bit flags for true or false values, and providing you don't go into too many dimensions, the quotemark conversion shouldn't become a problem.
Reply With Quote
  #9  
Old 07-11-2008, 10:04 PM
Kristi Kristi is offline
Bowie's Deciple
Kristi's Avatar
Join Date: Dec 2003
Location: Boston, MA
Posts: 748
Kristi has a spectacular aura aboutKristi has a spectacular aura about
Send a message via AIM to Kristi Send a message via MSN to Kristi
Quote:
Originally Posted by DustyPorViva View Post
No, I saved them just as numbers. I actually tried to keep it under 256 characters, but that doesn't account for future additions/long names, any other number of variables introduced by other staff. And anyways, when all done, all I had was a huge mess of numbers and quotes because graal turns {}'s into ""s, which is makes it even harder to read.
So use more then one variable, then it won't overflow. Crazy pills?
__________________
Reply With Quote
  #10  
Old 07-11-2008, 10:05 PM
DustyPorViva DustyPorViva is offline
Will work for food. Maybe
DustyPorViva's Avatar
Join Date: Sep 2003
Location: Maryland, USA
Posts: 9,589
DustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond reputeDustyPorViva has a reputation beyond repute
Send a message via AIM to DustyPorViva Send a message via MSN to DustyPorViva
Quote:
Originally Posted by Kristi View Post
So use more then one variable, then it won't overflow. Crazy pills?
That's even worse.
Reply With Quote
  #11  
Old 07-11-2008, 10:06 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
Quote:
Originally Posted by Kristi View Post
So use more then one variable, then it won't overflow. Crazy pills?
I had to do that just for the item's description.. >_>

I say fix the 255 char limit as Inverness said
__________________
Reply With Quote
  #12  
Old 07-11-2008, 09:56 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Regardless of what you call them, I like them because they allow custom items, as does everyone else. Strings are rather messy and a pain to deal with in my opinion.
__________________
Reply With Quote
  #13  
Old 07-11-2008, 09:57 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by cbk1994 View Post
Regardless of what you call them, I like them because they allow custom items, as does everyone else. Strings are rather messy and a pain to deal with in my opinion.
Strikes me that you might not be organising your strings in the best fashion, then. I've never found myself needing a text file for something that I couldn't do using existing engine stuff. :/
Reply With Quote
  #14  
Old 07-11-2008, 10:06 PM
cbk1994 cbk1994 is offline
the fake one
cbk1994's Avatar
Join Date: Mar 2003
Location: San Francisco
Posts: 10,718
cbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond reputecbk1994 has a reputation beyond repute
Send a message via AIM to cbk1994
Quote:
Originally Posted by Skyld View Post
Strikes me that you might not be organising your strings in the best fashion, then. I've never found myself needing a text file for something that I couldn't do using existing engine stuff. :/
I find it easier to load from text files than loading from a database of strings ... I'm not talking about how you store the strings in a player.

However, I usually use text files for that so that I can have multiple characters.

But, it's much easier for incompetent staff to edit some text files than strings in a database NPC without messing **** up.
__________________
Reply With Quote
  #15  
Old 07-11-2008, 09:57 PM
Chompy Chompy is offline
¯\(º_o)/¯
Chompy's Avatar
Join Date: Sep 2006
Location: Norway
Posts: 2,815
Chompy is just really niceChompy is just really niceChompy is just really nice
Send a message via MSN to Chompy
;O

I only use text files for items, item templates and players..
I usually cache them in forms of objects though :o

I could probably use a DB, but meh.. I like textfiles more, since then I don't need to give NC to people who make items :o
__________________
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 03:01 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.