Architectopedia - Advanced architect handbook
An advanced handbook for every architect who wants to polish his and her skills. It contains all the information you need about _MyScript variables to make your life easier (But my was not easy as I had to write it beforehand).
This idea came to me when TFMurphy told me about how MoveTo works. I have decided to make this Architectopedia. This is really big and detailed. I tried not to make mistakes. If you find some typos, grammar errors or other mistakes, I will be pleased to fix them, just tell me what is wrong. If you know of functionality of some other commands in game, I'll gladly listen. Version updated to DROD RPG 1.1:
First of all thanks to Mrimer for fixing all these bugs which I have managed to spot. Some others were found and I will post them on Bug Report board immediately. This time I wasn't checking everything (It would be too time consuming) but I tested all things which previously failed to work fine. At the bottom there is a change log, so take a look to see what changed.

So let us begin:

(1) - If anywhere you see word "Buzz" or "Buzzer", keep yourself away from that thing. Don't build that thing nor create such entity - or you will make yourself unhappy.
(2) - If I say CRASHES DROD! KEEP AWAY FROM IT! I mean it. Honestly speaking, it took me around 40 crashes to realize that I have spotted them all.
(3) - When being asked for Width and Height of rectangle, remember that length of 1 tile is represented by number 0. so a 1x1 square will have W=0 H=0, 5x8 -> W=4 H=7
(4) - When there is a number in parenthesis, it means that putting any other number is meaningless
(5) - Room size is 16x16. Top-left tile is 0x0, bottom right is 15x15
(6) - Things marked with (?) are potentially buggy, or not yet checked fully.
(7) - Flags - when something is said to be Flags you should have a list similar to this:
0 - Coordinates
1 - Player
2 - NPC
4 - Monster
8 - Self
16 - Stalwart
So if you set it to 1, the player will be selected. If to 2 NPC. 4 Monster and so on. IF, however, you wanted to select MORE than one at once, sum the values. So to select Player and mosnter 1+4=5. Stalwart+Self+NPC=16+8+2=26.
(8) At the bottom there is a list of other useful information about scripting I have found.

Activate Item At:_MyScriptX - X position of item to activate (0-15)_MyScriptY - Y position of item to activate (0-15)

Ambient Sound At:Remember that the closer you are to the sound, the louder it is and vice versa_MyScriptX - X position of sound to play (0-15)_MyScriptY - Y position of sound to play (0-15)

Appear At:_MyScriptX - X position to appear to (0-15)_MyScriptY - Y position to appear to (0-15)

Note! - When there is (?) next to item, or when there is Buzz, it means that in some non understandable for us way, that item can either be harmful for hold (The quotation mark) or almost for sure can be harmful (The buzz). Heed my suggestion, and don't use these!Note! - When there is list of items in Parenthesis, it means that these object will be deleted when building upon them. So:54-Floor Mosaic (All first category but platforms)
Means that when building 54, all walls, pits, water, hot tiles, oremites, etc, etc, except platforms will be removed to make space for Mosaic Floor.

...
Phew. After doing it, I feel like I gave something back to the community, and to DROD overall, for never having a chance to buy DROD .

Scripting Quirks:
-Global character script is activated AFTER characters placed in the room scripts.
-Variables are rounded down when divided
-2147483647 is the biggest positive number possible (Thanks to Sillyman)

Version 1.11:
-Added one more scripting quirk
Version 1.10:
-Full compatibility check with version 1.1 for all previously not working/crashing/buzzing functions!
-Updates in Build
-Updates in Generate Entity
-Updates in Game Effect
Version 1.01:
-Fixed Generate Entity - some Enemy IDs were wrong
Version 1.00:
-Released

Thanks for spending time figuring all this out and posting this guide. I haven't read through most of it yet, but I trust it is accurate.

quote:skell wrote:
(2) - When I say CRASHES DROD! KEEP AWAY FROM IT! I mean it. Honestly speaking, it took me around 40 crashes to realize that I have spotted them all.

If there are ways to use scripts to crash DROD, these are bugs needing to be fixed. May I meekly ask you to post specific scripts that will crash DROD if I run them on the Bugs board (if you haven't done so already) so that I may respond to them there as they get fixed?

____________________________
Gandalf? Yes... That's what they
used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the
turn of the tide.

quote:mrimer wrote:
May I meekly ask you to post specific scripts that will crash DROD if I run them on the Bugs board (if you haven't done so already) so that I may respond to them there as they get fixed?

It's (almost) a pleasure . I fixed some hold quickly which gives the examples of it, and attached it to my already existing Bug post regarding the same matter.

Two boxes are responsible seperately for horizontal and vertical movement. The positive values are to the right and down, wherein negative to the top and left.
To put it simply, if you want to move East you set West/East box to 1 (or any other positive value). To move West you set it to -1 (or any other negative value). The same goes for North and South. 1 for South, -1 for North.
And if you want to move diagonally, just set both boxes.

Wow, thanks skell. This will, I'm sure, be very helpful. Someone needed to write all the commands down. This scripting engine wasn't as self-explanatory as TCB.

____________________________
I believe in everything until it's
disproved. So I believe in fairies,
the myths, dragons. It all exists,
even if it's in your mind. Who's to
say that dreams and nightmares
aren't as real as the here and now?
John Lennon

I wanted to bump this because I found that if _MyScriptF is a character's ID, the script will check for that specific character instead of those general entities.

I suspect this will work with any script that will use _MyScriptF as a flag variable, though I haven't tested any others.

EDIT: Unfortunately, this is not entirely accurate. If _MyScriptF is set to a number relatively close (within ten numbers, both ways), the test will still reports "true". If _MyScriptF is set to a number far away from the character's ID on the number line (at least eleven numbers away), the test will report "false". There are neither beeps nor breaks, though this is still inconsistent behavior.

____________________________
It was going well until it exploded.~Scott Manley

quote:12th Archivist wrote:
EDIT: Unfortunately, this is not entirely accurate. If _MyScriptF is set to a number relatively close (within ten numbers, both ways), the test will still reports "true". If _MyScriptF is set to a number far away from the character's ID on the number line (at least eleven numbers away), the test will report "false". There are neither beeps nor breaks, though this is still inconsistent behavior.

It's not inconsistent at all. It's a binary flag. That means you can Wait for Entity Player/Monster/Stalwart all at once, for example, if you just add up the appropriate IDs (21 in this case, which is 10101 in binary).

Can somebody in the know compile architectopedia data for the Wait For Item script in DROD 4.0? I've learned that it interacts with _MyScriptF, but I don't know any details besides that. I want to avoid trial and error, if I can help it. Thanks!

Can somebody in the know compile architectopedia data for the Wait For Item script in DROD 4.0? I've learned that it interacts with _MyScriptF, but I don't know any details besides that. I want to avoid trial and error, if I can help it. Thanks!

I could probably do it sometime later. I'd be smarter this time though, not trial-and-erroring everything by myself, but rather look into the source code .