Login
User Name:

Password:



Register

Forgot your password?
do_owhere recursive
Author: Khonsu
Submitted by: Khonsu
Changes list / Addchange
Author: Khonsu
Submitted by: Khonsu
6Dragons mp3 sound pack
Author: Vladaar
Submitted by: Vladaar
AFKMud 2.2.3
Author: AFKMud Team
Submitted by: Samson
SWFOTEFUSS 1.5
Author: Various
Submitted by: Samson
Users Online
AhrefsBot, Gdub, DotBot

Members: 1
Guests: 56
Stats
Files
Topics
Posts
Members
Newest Member
489
3,792
19,647
597
Aileenutz

Today's Birthdays
There are no member birthdays today.
» SmaugMuds » General » Building » How do I add a spell at 100% ...
Forum Rules | Mark all | Recent Posts

How do I add a spell at 100% to a race or class?
< Newer Topic :: Older Topic >

Pages:<< prev 1, 2 next >>
Post is unread #21 Apr 27, 2009 9:18 pm   
Go to the top of the page
Go to the bottom of the page

Zeno
Sorcerer
GroupMembers
Posts723
JoinedMar 5, 2005

 
ch->pcdata->learned[gsn_fireball] = 100;

Would need the race ifcheck too, of course.

Post is unread #22 Apr 27, 2009 10:10 pm   
Go to the top of the page
Go to the bottom of the page

Banner
Magician
GroupMembers
Posts169
JoinedNov 29, 2005

 
Hm. That's nifty. Never tried to do that before.. *cough*

Post is unread #23 Apr 29, 2009 7:04 am   
Go to the top of the page
Go to the bottom of the page

irbobo
Fledgling
GroupMembers
Posts16
JoinedApr 8, 2009

 

Zeno said:

ch->pcdata->learned[gsn_fireball] = 100;

Would need the race ifcheck too, of course.


I must say that is pretty clean.

Post is unread #24 Apr 29, 2009 8:43 am   
Go to the top of the page
Go to the bottom of the page

David Haley
Sorcerer
GroupMembers
Posts903
JoinedJan 29, 2007

 
Another solution that doesn't require adding global variables for each skill you want to find is to look up the skill name in the skill table using the function skill_lookup (or whatever it's called) -- this will perform a binary search, which is much faster than a linear scan.

Pages:<< prev 1, 2 next >>