Implementing: Tradeskills

EQ2Emulator Development forum.

Moderator: Team Members

Post Reply
Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Tradeskills

Post by Jabantiz » Mon Mar 04, 2019 5:43 pm

This use to work, not sure what would have changed to break it.

Basically the spell script should be applying a spell bonus and those should be linked to the spell so when another is cast it should apply its own spell bonus. The spells bonus should then be removed when the spell expires and the remove lua function is called.

It sounds like remove is being triggered when another spell is applied or the character sheet is not correctly grabbing all the spell bonuses anymore so you could have them it is just not displaying.

i just committed a struct update to fix the character sheet i can have character sheet open and watch themods add and disapear(early)

User avatar
Ememjr
Team Member
Posts: 975
Joined: Wed Mar 15, 2017 9:41 am
EQ2Emu Server: Perseverance

Re: Implementing: Tradeskills

Post by Ememjr » Thu Mar 07, 2019 12:25 pm

i was able to create a table

Code: Select all

CREATE TABLE `eq2world7`.`spell_ts_ability_index`(  
  `id` INT(10) NOT NULL,AUTO_INCREMENT
  `spell_id` INT(10) UNSIGNED NOT NULL,
  `index` INT(10) NOT NULL,
  PRIMARY KEY (`id`)
);
and add the data to it
change .log to .sql
what i do not know how to do is get the index loaded into the world
the way i did on mine was to add a ts_loc_index to mmy spelldata struct, but unsure how to get the index db file to it
You do not have the required permissions to view the files attached to this post.

Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Tradeskills

Post by Jabantiz » Thu Mar 07, 2019 6:43 pm

If you are loading it into the spell struct then when the server loads the spells data check the spell type (spell_book_type I believe has the value for tradeskill spells) and if it is a tradeskill spell then call a function to get the index for the current spell id.

Table was added to the DB Patcher, new minor version is 29. You must set the minor version in versions.h for the server to grab the table. Also note that the Patcher adds a drop so when you do this to your server it will nuke your data.

The data itself is content related (spell id's) so it won't go up on the patcher and I will have to manually add it after the code is committed.

User avatar
Ememjr
Team Member
Posts: 975
Joined: Wed Mar 15, 2017 9:41 am
EQ2Emu Server: Perseverance

Re: Implementing: Tradeskills

Post by Ememjr » Wed Mar 13, 2019 11:47 am

Jabantiz wrote: Thu Mar 07, 2019 6:43 pm If you are loading it into the spell struct then when the server loads the spells data check the spell type (spell_book_type I believe has the value for tradeskill spells) and if it is a tradeskill spell then call a function to get the index for the current spell id.

Table was added to the DB Patcher, new minor version is 29. You must set the minor version in versions.h for the server to grab the table. Also note that the Patcher adds a drop so when you do this to your server it will nuke your data.

The data itself is content related (spell id's) so it won't go up on the patcher and I will have to manually add it after the code is committed.
have you loaded this data yet, i have committed the changes to worlddatabase(loadspells) spells.h(spell data structure) and the tradeskill packet

Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Tradeskills

Post by Jabantiz » Wed Mar 13, 2019 7:39 pm

Not yet as the table has not made it from the DB Patcher to the server yet. Did you update and commit the versions.h file with the number i posted?

Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Tradeskills

Post by Jabantiz » Wed Mar 13, 2019 8:19 pm

So the sql gave an error when I changed the version.h locally so i ended up manually creating the table and changing the sql on the patcher to this

Code: Select all

CREATE TABLE `spell_ts_ability_index` (
	`id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT,
	`spell_id` INT(10) UNSIGNED NOT NULL,
	`index` INT(10) UNSIGNED NOT NULL,
	PRIMARY KEY (`id`)
)
COLLATE='latin1_general_ci'
ENGINE=InnoDB
;
I will commit the version.h and compile the server later tonight when no one is on it.

User avatar
Ememjr
Team Member
Posts: 975
Joined: Wed Mar 15, 2017 9:41 am
EQ2Emu Server: Perseverance

Re: Implementing: Tradeskills

Post by Ememjr » Thu Mar 14, 2019 3:07 am

Jabantiz wrote: Wed Mar 13, 2019 7:39 pm Not yet as the table has not made it from the DB Patcher to the server yet. Did you update and commit the versions.h file with the number i posted?
ah no i did not, i did not relize i would have to add it to get emu to use it

Jabantiz
Lead Developer
Posts: 2912
Joined: Wed Jul 25, 2007 2:52 pm
Location: California

Re: Implementing: Tradeskills

Post by Jabantiz » Thu Mar 14, 2019 5:21 pm

This was committed last night btw and I added the data but it was after the server started so it will probably need a /reload spells assuming the info loads with spells, if not then a server restart

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest