Angband.oook.cz
Angband.oook.cz
AboutVariantsLadderForumCompetitionComicScreenshotsFunniesLinks

Go Back   Angband Forums > Angband > Development

Reply
 
Thread Tools Display Modes
Old July 9, 2016, 04:02   #1
Elfin Jedi
Adept
 
Join Date: Mar 2013
Posts: 102
Elfin Jedi is on a distinguished road
Adding Oangband magic realms/spellbooks. What changes do I need to make?

I am trying to add the nature and necromancy magic realms from Oangband to 4.0.4.

So far I have successfully added the new classes (druid, necromancer, assassin) by giving them clones of the mage and rogue spell sets, and added nature and necromancy spellbooks to object_base.

However it doesn't like it when I add the spellbooks to the object file (it gets a parse error, I don't see any problems with what I have entered so far).

I managed to get the code to compile, added the nature and necromancy realms to list-magic-realms.h and successfully recompiled. And now I have added nature books and necromancy books to obj-tval.c (which it is not happy about). What else do I need to do to get it to accept spellbooks as objects?
Elfin Jedi is offline   Reply With Quote
Old July 9, 2016, 04:37   #2
AnonymousHero
Veteran
 
AnonymousHero's Avatar
 
Join Date: Jun 2007
Posts: 1,320
AnonymousHero is on a distinguished road
Are you sure you shouldn't just be playing FAAngband? (Given the classes you've added.)
AnonymousHero is offline   Reply With Quote
Old July 9, 2016, 04:39   #3
Nick
Vanilla maintainer
 
Nick's Avatar
 
Join Date: Apr 2007
Location: Canberra, Australia
Age: 52
Posts: 6,702
Donated: $60
Nick is on a distinguished road
Awesome, this is the sort of thing I wanted to enable

You will need to add nature and necromancy books to list-tvals.h, if you haven't already - let me know how it goes.
__________________
One Ring to rule them all, One Ring to find them,
One Ring to bring them all and in the darkness bind them.
Nick is offline   Reply With Quote
Old July 9, 2016, 04:50   #4
Carnivean
Swordsman
 
Join Date: Sep 2013
Posts: 476
Carnivean is on a distinguished road
Are realms even a necessary construct at this point? (From a technical standpoint, not a UI one)

You can create a spell from the effects of other spells from either realm in the spell list. Mages can have priest spells in their list (and vice versa) simply by copying the effects from the appropriate spell.
Carnivean is offline   Reply With Quote
Old July 9, 2016, 07:40   #5
Elfin Jedi
Adept
 
Join Date: Mar 2013
Posts: 102
Elfin Jedi is on a distinguished road
Quote:
Originally Posted by AnonymousHero View Post
Are you sure you shouldn't just be playing FAAngband? (Given the classes you've added.)
Actually, I want to make other changes besides just the magic/class system. I am adding monsters and races from Unangband, hopefully terrain eventually too, and races from Eyangband. And eventually I would like to make it so you can choose between a Poschengband race(? might try to combine the 2 systems)/class/magic system and the other one at character creation.

Ok, now it launches and functions ok, except that it doesn't display the name of the spellbook in my inventory list. There is instead a blank entry for a) which can be browsed or cast from normally.
Elfin Jedi is offline   Reply With Quote
Old July 9, 2016, 14:53   #6
takkaria
Veteran
 
takkaria's Avatar
 
Join Date: Apr 2007
Posts: 1,828
Donated: $40
takkaria is on a distinguished road
Quote:
Originally Posted by Elfin Jedi View Post
Actually, I want to make other changes besides just the magic/class system. I am adding monsters and races from Unangband, hopefully terrain eventually too, and races from Eyangband. And eventually I would like to make it so you can choose between a Poschengband race(? might try to combine the 2 systems)/class/magic system and the other one at character creation.

Ok, now it launches and functions ok, except that it doesn't display the name of the spellbook in my inventory list. There is instead a blank entry for a) which can be browsed or cast from normally.
You need to add a couple of case statements to obj_desc_get_basename() in obj-desc.c to get the names to show up.
__________________
"Physician, heal thyself."
takkaria is offline   Reply With Quote
Old July 9, 2016, 14:57   #7
Pete Mack
Prophet
 
Join Date: Apr 2007
Location: Seattle, WA
Posts: 4,346
Donated: $40
Pete Mack is on a distinguished road
Hmm. Looks like (at least) two files need to be fixed so they use object-base.txt.
This one, and ui-knowledge.c

Quote:
Originally Posted by takkaria View Post
You need to add a couple of case statements to obj_desc_get_basename() in obj-desc.c to get the names to show up.
Pete Mack is offline   Reply With Quote
Old July 9, 2016, 15:45   #8
Elfin Jedi
Adept
 
Join Date: Mar 2013
Posts: 102
Elfin Jedi is on a distinguished road
How do I fix ui-knowledge.c?
Elfin Jedi is offline   Reply With Quote
Old July 9, 2016, 18:08   #9
Pete Mack
Prophet
 
Join Date: Apr 2007
Location: Seattle, WA
Posts: 4,346
Donated: $40
Pete Mack is on a distinguished road
Add your base type to the monster_group array at line ~1058.
Pete Mack is offline   Reply With Quote
Old July 9, 2016, 19:48   #10
Elfin Jedi
Adept
 
Join Date: Mar 2013
Posts: 102
Elfin Jedi is on a distinguished road
Ok, I updated obj-desc.c and ui-knowledge.c (both monsters and objects). The spellbooks still don't display in inventory list. What am I missing?

Also, rebalancing monsters still crashes.

By the way I started a github account: Elfin-Jedi. It might still be a bit of a mess.
Elfin Jedi is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
[PosChengband] Making Realms Questions riftor_77 Development 5 August 4, 2014 13:24
Spellbooks as artifacts TJS Vanilla 48 July 29, 2010 06:12
Sangband and spell realms Malak Darkhunter Variants 21 March 18, 2009 05:03
Spellbooks curinor Variants 3 April 20, 2008 14:38
Spellbooks curinor Vanilla 1 April 19, 2008 23:07


All times are GMT +1. The time now is 03:13.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.