View Single Post
  #1  
Old 03-11-2002, 04:10 AM
Drawde
Dragon
 
Join Date: Jan 2002
Posts: 521
Default Idea for starting items

Starting items and spells for characters would be a useful feature for the emulator (I think so at least), although it doesn't take long to #summonitem them, it would be a nice touch.

You could have a struct in the DB like this (more or less):

CREATE TABLE starting_items (
id int(11) unsigned NOT NULL auto_increment,
item_id int(11) NOT NULL default '0',
class int(11) NOT NULL default '0',
race int(11) NOT NULL default '0',
PRIMARY KEY (id,item_id),
) TYPE=MyISAM;

This would be an entry to give Human Warriors a short sword on startup:
INSERT INTO starting_items VALUES(1,9998,1,1);

When a new character is created, the server searches through this table in the DB and any items with a matching class and race are added to their inventory.
It would be easily editable so you could modify it to give your characters high-level items if you wanted, for example.
The race value is needed as well as class, since different races get different starting robes/tunics and occasionally weapons (Iksar at least)
Reply With Quote