Wenn die Vagrant Skills (1,2,3) nicht eingetragen lässt der Slot einem das Spiel abstürzen wenn man versucht einen Skill reinzuziehen.
In den Action Slot kann man mehrere Skills ziehen damit diese schneller ausgeführt werden.
Hier mal meine Tabelle.
Es geht nur um die Tabelle Characters und die Spalten
skills
text NOT NULL,
skill_levels
text NOT NULL,
Via der Spalte accountname
text NOT NULL, möchte ich den Datenbankeintrag auswählen lassen. Der jenige soll in das Formular einfach seinen Accountname eintragen und dann werden alle Chars gefixt die er derzeit besitzt. Und wenn man es noch ganz übertreiben will könnte man sogar ausgeben welche JobKlasse er ist
Allerdings muss dies eben geschehen wenn der Char erstellt wurde weil der Server dann erst seine Daten in die Tabelle schreibt.
Also so solls aussehen.
Spieler registriert sich. Erstellt einen Account. Erstellt einen Character. Spieler geht auf die HP und fixt seinen Slot.
Sollte bei einem Char etwas anderes als 0 oder 0,0,0,… stehen dann soll ein echo ausgegeben werden. Am besten welche Chars schon gefixt sind bzw. wo schon den 1. JobChange gemacht haben. Und was auch super wäre wenn da dann stehen würde
"Dein Character charname ist schon class"
Man müsste dann halt die Zahl wo bei class steht noch eine Bezeichnung geben.
Hier mal die Struktur und einen funktionieren Char und einen der buggy ist.
– Host: localhost
– Erstellungszeit: 02. Oktober 2008 um 08:57
– Server Version: 5.0.51
– PHP-Version: 5.2.6
SET SQL_MODE=“NO_AUTO_VALUE_ON_ZERO”;
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT /;
/!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS /;
/!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION /;
/!40101 SET NAMES utf8 */;
–
– Datenbank: flyff
–
– Tabellenstruktur für Tabelle accounts
CREATE TABLE IF NOT EXISTS accounts
(
id
int(255) NOT NULL auto_increment,
username
varchar(32) NOT NULL default ‘’,
password
varchar(32) NOT NULL default ‘’,
accesslevel
int(3) NOT NULL default ‘0’,
logged_in
int(1) NOT NULL default ‘0’,
channelnum
int(255) NOT NULL default ‘0’,
bankpassword
int(4) NOT NULL default ‘0’,
bankpenya1
int(9) NOT NULL default ‘0’,
bankpenya2
int(9) NOT NULL default ‘0’,
bankpenya3
int(9) NOT NULL default ‘0’,
PRIMARY KEY (id
)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=58 ;
–
– Tabellenstruktur für Tabelle characters
CREATE TABLE IF NOT EXISTS characters
(
channelnum
varchar(255) NOT NULL,
charname
text NOT NULL,
level
int(10) NOT NULL default ‘1’,
class
int(10) NOT NULL default ‘0’,
sex
int(10) NOT NULL default ‘0’,
hairstyle
int(10) NOT NULL default ‘0’,
haircolor
int(10) NOT NULL default ‘0’,
eyestyle
int(10) NOT NULL default ‘0’,
stat_str
int(10) NOT NULL default ‘15’,
stat_sta
int(10) NOT NULL default ‘15’,
stat_dex
int(10) NOT NULL default ‘15’,
stat_int
int(10) NOT NULL default ‘15’,
charslot
int(10) NOT NULL default ‘0’,
id
int(10) NOT NULL auto_increment,
posX
int(10) NOT NULL default ‘6973’,
posY
int(10) NOT NULL default ‘10’,
posZ
int(10) NOT NULL default ‘3328’,
guild_id
int(10) NOT NULL default ‘0’,
posWorldID
int(10) NOT NULL default ‘1’,
accountname
text NOT NULL,
penya
int(9) NOT NULL default ‘1000000000’,
exp
float NOT NULL,
curhp
int(10) NOT NULL default ‘10000’,
curmp
int(10) NOT NULL default ‘10000’,
curfp
int(10) NOT NULL default ‘10000’,
karma_point
int(10) NOT NULL default ‘0’,
duel_point
int(10) NOT NULL default ‘0’,
killing_point
int(10) NOT NULL default ‘0’,
skills
text NOT NULL,
skill_levels
text NOT NULL,
fslot1_opcodes
text NOT NULL,
fslot1_ids
text NOT NULL,
fslot1_text
text NOT NULL,
fslot2_opcodes
text NOT NULL,
fslot2_ids
text NOT NULL,
fslot2_text
text NOT NULL,
fslot3_opcodes
text NOT NULL,
fslot3_ids
text NOT NULL,
fslot3_text
text NOT NULL,
fslot4_opcodes
text NOT NULL,
fslot4_ids
text NOT NULL,
fslot4_text
text NOT NULL,
hotslot_opcodes
text NOT NULL,
hotslot_ids
text NOT NULL,
hotslot_text
text NOT NULL,
flying_level
int(10) NOT NULL default ‘0’,
flying_exp
float NOT NULL default ‘0’,
skillpoints
int(3) NOT NULL default ‘0’,
statpoints
int(3) NOT NULL default ‘0’,
messenger_state
int(1) NOT NULL default ‘0’,
posAngle
int(10) NOT NULL default ‘1’,
sizeMod
int(10) NOT NULL default ‘1’,
party_id
int(10) NOT NULL default ‘0’,
buffpet_itemnum
int(10) NOT NULL default ‘0’,
disposition
int(10) NOT NULL default ‘0’,
actionslot_opcodes
text NOT NULL,
actionslot_ids
text NOT NULL,
actionslot_text
text NOT NULL,
partyDefaultName
text NOT NULL,
canJoinGuildAt
int(10) NOT NULL default ‘0’,
actionslot_cooldown
int(10) NOT NULL default ‘0’,
allowViewEquipment
int(10) NOT NULL default ‘0’,
allowPVPDuelRequests
int(10) NOT NULL default ‘0’,
fslot5_opcodes
text NOT NULL,
fslot5_ids
text NOT NULL,
fslot5_text
text NOT NULL,
fslot6_opcodes
text NOT NULL,
fslot6_ids
text NOT NULL,
fslot6_text
text NOT NULL,
fslot7_opcodes
text NOT NULL,
fslot7_ids
text NOT NULL,
fslot7_text
text NOT NULL,
fslot8_opcodes
text NOT NULL,
fslot8_ids
text NOT NULL,
fslot8_text
text NOT NULL,
bag1_last_until
int(10) NOT NULL default ‘0’,
bag2_last_until
int(10) NOT NULL default ‘0’,
PRIMARY KEY (id
)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=180 ;
[/code]
Und hier mal das Beispiel bei einem bugfreien User.
--
-- Daten für Tabelle `characters`
--
INSERT INTO `characters` (`channelnum`, `charname`, `level`, `class`, `sex`, `hairstyle`, `haircolor`, `eyestyle`, `stat_str`, `stat_sta`, `stat_dex`, `stat_int`, `charslot`, `id`, `posX`, `posY`, `posZ`, `guild_id`, `posWorldID`, `accountname`, `penya`, `exp`, `curhp`, `curmp`, `curfp`, `karma_point`, `duel_point`, `killing_point`, `skills`, `skill_levels`, `fslot1_opcodes`, `fslot1_ids`, `fslot1_text`, `fslot2_opcodes`, `fslot2_ids`, `fslot2_text`, `fslot3_opcodes`, `fslot3_ids`, `fslot3_text`, `fslot4_opcodes`, `fslot4_ids`, `fslot4_text`, `hotslot_opcodes`, `hotslot_ids`, `hotslot_text`, `flying_level`, `flying_exp`, `skillpoints`, `statpoints`, `messenger_state`, `posAngle`, `sizeMod`, `party_id`, `buffpet_itemnum`, `disposition`, `actionslot_opcodes`, `actionslot_ids`, `actionslot_text`, `partyDefaultName`, `canJoinGuildAt`, `actionslot_cooldown`, `allowViewEquipment`, `allowPVPDuelRequests`, `fslot5_opcodes`, `fslot5_ids`, `fslot5_text`, `fslot6_opcodes`, `fslot6_ids`, `fslot6_text`, `fslot7_opcodes`, `fslot7_ids`, `fslot7_text`, `fslot8_opcodes`, `fslot8_ids`, `fslot8_text`, `bag1_last_until`, `bag2_last_until`) VALUES
('-1', '<GM>KevinsComputer', 120, 31, 0, 4, -10192011, 4, 15, 239, 21, 239, 0, 83, 1205, 85, 735, 0, 201, 'kevinscomputer', 999999992, 2, 33127, 6564, 1036, 0, 0, 0, '1,2,3,64,65,69,70,107,118,119,120,121,30,31,32,33,34,35,36,37,0,0,0,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,0,313,241', '10,10,10,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,0,0,0,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,10,0,5,5', '6,6,6,6,6,6,6,6,6', '25,31,37,28,34,38,40,39,41', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '9,8,8,8,8,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ.evann 20 UHR SERVER DOWNÿ.evann DOWN WEGEN HAMACHI FREIÿ.evann DOWNTIME UNBEKANNTÿ.evann Server Neustart in 1 Minute bitte ausloggenÿ ÿ ÿ ÿ ', '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '6,6,6,6,6,6,6,8,8,8,0,0,0,0,0,0,0,0', '24,30,36,27,33,43,44,0,0,0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ.serverstatsÿ/createitem ÿ.evann NEUEN CLIENT NUTZEN BITTE DANKESCHOENÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', 1, 0, 34, 0, 0, 325, 1, 0, -1, 0, '6,6,6,6,6', '37,37,37,37,37', '', '', 0, 0, 0, 0, '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', '0,0,0,0,0,0,0,0,0', '0,0,0,0,0,0,0,0,0', ' ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', 1225244950, 1225244956);
Und hier ein verbuggter
[code]–
– Daten für Tabelle characters
INSERT INTO characters
(channelnum
, charname
, level
, class
, sex
, hairstyle
, haircolor
, eyestyle
, stat_str
, stat_sta
, stat_dex
, stat_int
, charslot
, id
, posX
, posY
, posZ
, guild_id
, posWorldID
, accountname
, penya
, exp
, curhp
, curmp
, curfp
, karma_point
, duel_point
, killing_point
, skills
, skill_levels
, fslot1_opcodes
, fslot1_ids
, fslot1_text
, fslot2_opcodes
, fslot2_ids
, fslot2_text
, fslot3_opcodes
, fslot3_ids
, fslot3_text
, fslot4_opcodes
, fslot4_ids
, fslot4_text
, hotslot_opcodes
, hotslot_ids
, hotslot_text
, flying_level
, flying_exp
, skillpoints
, statpoints
, messenger_state
, posAngle
, sizeMod
, party_id
, buffpet_itemnum
, disposition
, actionslot_opcodes
, actionslot_ids
, actionslot_text
, partyDefaultName
, canJoinGuildAt
, actionslot_cooldown
, allowViewEquipment
, allowPVPDuelRequests
, fslot5_opcodes
, fslot5_ids
, fslot5_text
, fslot6_opcodes
, fslot6_ids
, fslot6_text
, fslot7_opcodes
, fslot7_ids
, fslot7_text
, fslot8_opcodes
, fslot8_ids
, fslot8_text
, bag1_last_until
, bag2_last_until
) VALUES
(’-1’, ‘Dextery’, 106, 8, 0, 4, -10192011, 4, 134, 15, 106, 15, 0, 152, 6940, 100, 3230, 1, 1, ‘pursuer’, 1140541971, 0, 8822, 272, 521, 0, 0, 0, ‘0,0,0,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,0,0,0,0,207,208,209,210,211,212,213,214,0,0,0,0,0,0,0,0,0,0,0,0,0,0’, ‘0,0,0,20,0,8,0,6,0,3,0,20,0,0,0,10,0,4,4,0,0,0,0,10,10,0,4,0,10,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0’, ‘3,5,6,6,6,6,6,6,5’, ‘27,3,28,9,23,24,11,3,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', 1, 0, 229, 0, 0, 318, 1, 0, -1, 0, ‘0,0,0,0,0’, ‘0,0,0,0,0’, ‘’, ‘AdvanceParty’, 0, 0, 0, 0, ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', ‘0,0,0,0,0,0,0,0,0’, ‘0,0,0,0,0,0,0,0,0’, ’ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ', 0, 0);
[/code]