In other words in order to find something you need to memorize entire code or if not that do multiple searches for every single function in order to figure out what they do.
A spaghetti code. A very hard to figure out spaghetti code.
Except maybe if you are a professional coder.
Angband code for dummies?
Collapse
X
-
-
So you open up dungeon.c and find play_game, and you notice that everything else follows from there. In general, the z-* files are the really low level things - messing with numbers, strings and files. The subdirs player/, object/ and monster/ are pretty self-explanatory. I guess the tricky stuff is in the cmdX.c files, which take a bit of getting used to.Leave a comment:
-
I already have IT career (have been over a decade now), but all I need is some scripting skills which I already have.Leave a comment:
-
Hm, I'm generally able to find what I need, by searching for a string I know occurs in-game, and then working back from there. For example, if I want to look up shards damage, I would search for "You are hit by something sharp!" (the message you get when hit by shards while blind), which would get me to the code that processes shards hits, and I can search for what calls that function, and find one for breathing which refers to BR_SHAR_MAX, which I can search for to find that the damage cap for shards is 500.
Ultimately it's mostly a matter of being good at using search utilities. I will freely admit that Angband would be easier for me to read if it had a more object-oriented design, mostly because that's the kind of design I'm used to dealing with. But we'd need a full-on recoding effort to make that happen. I'd recommend just learning how to navigate unfamiliar code that isn't laid out the way you expect. If you're expecting to program as part of your career, it's a skill that will hold you in good stead.Leave a comment:
-
Everywhere. File relations, function relations etc. For example I need to look inside three different files to figure out simple damage calculation for manastorm: what exactly does it do, and I'm not sure that is even enough. Nobody can figure out that without some help or memorizing out every single file what they contain.Leave a comment:
-
I used to be able to interpreter vanilla angband code and what does what, but currently I find it more a uncommented spaghetti code that is impossible to follow. Is there any Angband code for dummies around? Some sort of flowchart that tells which function is doing what? Which files have which purpose? Anything?
T.Leave a comment:
-
Angband code for dummies?
I used to be able to interpreter vanilla angband code and what does what, but currently I find it more a uncommented spaghetti code that is impossible to follow. Is there any Angband code for dummies around? Some sort of flowchart that tells which function is doing what? Which files have which purpose? Anything?Tags: None
Leave a comment: