Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Sticz

#1
I have been fidgeting with a code to make a specific door locked, unpickable and using a key. The code below works for making it use a key. I now need an example of locking the door (which would be the same as this but only minor changes, I dont know what numbers to use inplace of BOR 0b00000100) specifying a key, and setting the lock-picking dificulty to 100.

// makes doors actually require keys that they are listed as requiring
COPY_EXISTING ~AR0329.ARE~ ~override~
READ_LONG 0xa4 "door_num"
READ_LONG 0xa8 "door_off"
WHILE ("%door_num%" > 0) BEGIN
SET "door_num" = ("%door_num%" - 1)
READ_ASCII ("%door_off%" + ("%door_num%" * 0xc8)) "doorname"
READ_BYTE ("%door_off%" + 0x29 + ("%door_num%" * 0xc8)) "usekey"
PATCH_IF ((("%doorname%" STRING_COMPARE_CASE "DOOR07" = 0) OR ("%doorname%" STRING_COMPARE_CASE "DOOR08" = 0))
AND ("%usekey%" BOR 0b11111011 = 0b11111011)) BEGIN
WRITE_BYTE ("%door_off%" + 0x29 + ("%door_num%" * 0xc8)) ("%usekey%" BOR 0b00000100) // sets uses key bit
END
END
BUT_ONLY_IF_IT_CHANGES

I have seen examples of what I am needing to do, they are too specific though, and will not allow the mod to work with other mods that may modify the area. Any examples? This set of code is from the G3 fixpack.


Sticz
#2
I want to add a lock to an existing door that uses a key, and is not unlockable using pick-lock or knock.

What lines of code would I need for this, using WeiDu?

Sticz
#3
Modder's Workshop / Automap Notes
August 16, 2006, 07:18:28 PM
Thanks! I will try that as soon as I get home!

Sticz   B)
#4
Modder's Workshop / Automap Notes
August 16, 2006, 06:50:27 PM
Yes, I want the area to have pre-positioned notes.  B)


Sticz
#5
Modder's Workshop / Automap Notes
August 16, 2006, 06:26:28 PM
I am trying to add new areas (basically existing areas that I have rifled through to make a new area off of AR2600). The problem is that all of the existing tutorials list ways of adding new points to existing areas. I need to be able to insert the new points and text as they are loaded.

I am really unsure how offsets work, so I would need a brief explanation on how to determine the offset for any type of automap note. I have looked at many Mods, and they all use offsets, how do I get these alpha-numeric representations to make sense to me?

I am looking for an example line of code, if anyone has any hints, suggestions or snyde remarks, please let me know.  B)


Sticz