Announcement: Be excellent to each other.


Caravel Forum : DROD Boards : Bugs : Wait for Item At can't find pressure plates directly under the character
New Topic New Poll Post Reply
Poster Message
Xindaris
Level: Smitemaster
Avatar
Rank Points: 1531
Registered: 06-13-2015
IP: Logged

File: Plate Detection Bug.hold (1.6 KB)
Downloaded 40 times.
License: Public Domain
icon Wait for Item At can't find pressure plates directly under the character (+2)  
-If a character, with or without the use of Myscript, is instructed to check only the tile it's standing on for any other item, such as a powder keg, it sees it just fine.
-If a character under the same conditions tries to detect any kind of pressure plate, it doesn't see it.

I've attached the room I was using to try and see what was wrong with a character I was using this code for. The thing in the top right is pushable and non-stunnable, and uses myscripts to detect what's under it, and is supposed to change to a "weighing down" appearance if it sees a pressure plate, a wraithwing if it doesn't; it just instantly turns into a wraithwing and stays that way.
The two citizens illustrate the problem more precisely: They have identical code except the north one is looking for pressure plates while the south one is looking for powder kegs. Even if you change the code to one that doesn't use myscript at all, as long as it only looks at the tile under the character, the top one works and the bottom one doesn't. The top one does detect pressure plates anywhere it isn't currently standing, though.

____________________________
109th Skywatcher

Here are some links to Things!
Click here to view the secret text


[Last edited by Xindaris at 01-18-2016 09:44 PM]
01-18-2016 at 03:24 AM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 5056
Registered: 02-04-2003
IP: Logged
icon Re: Wait for Item At can't find pressure plates directly under the character (0)  
What version are you using?

____________________________
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.
01-18-2016 at 03:49 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
Xindaris
Level: Smitemaster
Avatar
Rank Points: 1531
Registered: 06-13-2015
IP: Logged
icon Re: Wait for Item At can't find pressure plates directly under the character (0)  
I'm using the version from the patch in the "TSS 5.1" topic (5.1.0.6345). Prior to using this version, pressure plate detection worked perfectly with the "Wait for Item at" set to the one kind of pressure plate available, which returned true for any pressure plate at all in the indicated location. So I guess there might be an error in how the new, more specific pressure plate detection was implemented?

____________________________
109th Skywatcher

Here are some links to Things!
Click here to view the secret text


[Last edited by Xindaris at 01-18-2016 09:45 PM]
01-18-2016 at 09:43 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
kieranmillar
Level: Smitemaster
Rank Points: 2670
Registered: 07-11-2014
IP: Logged
icon Re: Wait for Item At can't find pressure plates directly under the character (+2)  
I have played around with this and discovered the issue. It has nothing to do with MyScript or characters etc.

Wait for Item will only detect pressure plates in the top-left square if the pressure plate is more than one-tile large.

When verifying I only used one-square large pressure plates so I missed this one :lol

If there is no top-left square, then it looks for the left-most square, then the top-most one if multiple ones occupy that column.

This is demonstratable in the hold attached to the original post by pushing the roach/wraitwing character into the top-left hand corner of each PP, in which case he then turns into what he is supposed to. I have also verified it in a much more simple case in a separate test hold.

[Last edited by kieranmillar at 01-18-2016 10:50 PM : Wow I don't know my left from right. What a dummy.]
01-18-2016 at 10:25 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
skell
Level: Legendary Smitemaster
Avatar
Rank Points: 3734
Registered: 12-28-2004
IP: Logged
icon Re: Wait for Item At can't find pressure plates directly under the character (+2)  
Fixed, now it detects pressure plates correctly. Moreover, Wait for item didn't work correctly with orbs which is also fixed (there are 4 types of orbs to check: any, normal, cracked and broken)

____________________________
My website | Facebook | Twitter
01-24-2016 at 08:10 PM
View Profile Send Private Message to User Send Email to User Visit Homepage Show all user's posts High Scores This architect's holds Quote Reply
Xindaris
Level: Smitemaster
Avatar
Rank Points: 1531
Registered: 06-13-2015
IP: Logged
icon Re: Wait for Item At can't find pressure plates directly under the character (+2)  
I can confirm that as of the latest patch in the "5.1" thread, the scripts I have relying on pressure plate detection like the one in the first post here now work properly.

____________________________
109th Skywatcher

Here are some links to Things!
Click here to view the secret text


[Last edited by Xindaris at 02-17-2016 03:56 PM]
02-17-2016 at 03:56 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
New Topic New Poll Post Reply
Caravel Forum : DROD Boards : Bugs : Wait for Item At can't find pressure plates directly under the character
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.