« Return to Thread: Biodiversity patch

Re: Biodiversity patch

by Bugzilla from enderandrew@gmail.com :: Rate this Message:

Reply to Author | View in Thread

On 9/18/07, xkernigh@... <xkernigh@...> wrote:
> Because it runs LevComp, it should also make the other .lev files that
> use gehennom.des as the source.

Outstanding.  That's what I needed to know.

> Edit the include/config.h file. This is the normal way to configure
> SLASH'EM if you are not using the configure script.

That's what I ended up doing, but I wasn't sure it was right.

I also compiled the vanilla slash'em without the patch to see what
compile warnings I'd get, so I can see which errors I'm causing (which
I'm sure will be a few) and I got three compile warnings, two of which
I was able to fix.  I should make a separate patch for that tiny fix
and submit it.

I also can't seem to fix the third, which is frustrating me.

Oh well, my knowledge of C is minuscule at best, I just started
reading a book, and I'm not even all the way through it.  However, the
first warning I got with the biodiversity patch wasn't a proper
compiler warning, and I didn't recognize the error code.  Eventually I
grepped for the error, and found the spot in code that spits out that
specific error "prob error class foo", and started digging and
realizing that the probabilities for a certain object class weren't
adding up correctly, and it is the spellbook class.  There is only one
item in that class added by the patch, so hopefully I can fix that on
my own.  I imagine that attempting to fix these things will teach me a
few things about the Slash'em source, but my main concern is that I
won't be able to fix all the bugs properly myself.

I'm going to get as far as I can, and then share the patch and let
people see the monstrosity I've attempted to port over.

Oh, I do have another fairly big/important question.

win/share/monsters.txt and win/share/objects.txt

The patch wanted to take a tile number associated with an existing
item and/or monster, and add the new items in, duplicating tile
numbers.  Obviously all of the numbers were off since the patch was
for slash'em.  I saw three possible ways to handle this.

1 - Do exactly what the patch wants.  The sphinx monster should share
a tile number with a tiger for instance, but nothing else shares tile
numbers, and this just seems both lazy and incorrect.

2 - Add everything to the end, which is quick, and easy for anyone to
see the new stuff, and give each item a unique consecutive number like
everything else.

3 - This seems the most correct, but no doubt will be VERY time
consuming, and will make the patch HUGE.  Put the new items with their
groups, so the sphinx will go after the tiger, and then renumber every
tile.

Thank you so much for your help.  I understand these are basic
questions, and I could probably answer the above question on my own by
digging through the code enough, but my main concern tonight is to
spend some time and try to get this puppy to even compile first.  I
also figured that even if I found the code that parsed
win/share/monsters.txt, it wouldn't necessarily answer what was best
to do.  I imagine in practice, any of the above three might work, but
three is best solution in the long run, while options 2 and 3 also
mean more work for adapting graphical tiles for the game to account
for the new monsters/objects.

-- T. J. Brumfield
"In the beginning the Universe was created. This has made a lot of
people very angry and been widely regarded as a bad move."
--Douglas Adams
"Nihilism makes me smile."
--Christopher Quick

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Slashem-devel mailing list
Slashem-devel@...
https://lists.sourceforge.net/lists/listinfo/slashem-devel

 « Return to Thread: Biodiversity patch