Bug: taking what you are standing/sitting/lying on
Bug: taking what you are standing/sitting/lying on
Hi all,
I just stumbled across this bug, which makes the runner freeze. If the player tries to pick up the dynamic object the player is standing, sitting or lying on, the runner freezes. I attach a demo with a simple fix: The task "get something when on it" fixes the problem. If you delete this task you can make the runner freeze by typing "stand on table" followed by "get table".
I have made a bug report here: http://www.adrift.co/bug/19172
Please up-vote it.
There are now quite a few bugs in the standard library which can be solved. Perhaps it would be a good idea to put a list of known issues and solutions in one place?
I just stumbled across this bug, which makes the runner freeze. If the player tries to pick up the dynamic object the player is standing, sitting or lying on, the runner freezes. I attach a demo with a simple fix: The task "get something when on it" fixes the problem. If you delete this task you can make the runner freeze by typing "stand on table" followed by "get table".
I have made a bug report here: http://www.adrift.co/bug/19172
Please up-vote it.
There are now quite a few bugs in the standard library which can be solved. Perhaps it would be a good idea to put a list of known issues and solutions in one place?
- Attachments
-
- get_what_you_stand_on_bug.taf
- (14.85 KiB) Downloaded 153 times
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
Re: Bug: taking what you are standing/sitting/lying on
Thanks Denk.
Voted up, one notch
Voted up, one notch

D-Day in progress 86Kb (Slowly drifting)
October 31st: 60Kb (possible entry for IFComp 2021
)
October 31st: 60Kb (possible entry for IFComp 2021

Re: Bug: taking what you are standing/sitting/lying on
This bug affects Dynamic Containers as well as Dynamic Supporters. My setup is like yours, Denk, in that I tried making Specific tasks to make you get off or out of dynamic supporters or dynamic containers before taking them but my setup can't detect nested objects. For instance, go inside a portable tent, sit on a chair inside the tent, and then attempt to take the tent that you are technically still inside of will cause the runner to hang up.
Macro I used to test my demo (last line will cause the hang up because of nesting, remove if you want to test the rest leading up to that point)
The transcript illustrates my partial solution. Transcript gets written to all the way up to the task that hangs the runner which happens because we are taking the tent while sitting on the chair that is inside the tent:
Macro I used to test my demo (last line will cause the hang up because of nesting, remove if you want to test the rest leading up to that point)
Code: Select all
sit on chair
take chair
go inside tent
take tent
drop tent
go inside tent
sit on chair
drop chair
sit on chair
take tent
Code: Select all
> sit on chair
You sit on the light-weight chair.
> take chair
(getting off the light-weight chair first) Ok, you pick up the light-weight chair.
> go inside tent
You step inside the portable sitting tent.
> take tent
(getting out of the portable sitting tent first) Ok, you pick up the portable sitting tent.
> drop tent
Ok, you put down the portable sitting tent.
> go inside tent
You step inside the portable sitting tent.
> sit on chair
You can't sit on something that you are holding!
> drop chair
Ok, you put down the light-weight chair.
> sit on chair
You sit on the light-weight chair.
> take tent
Ok, you pick up the portable sitting tent.
Re: Bug: taking what you are standing/sitting/lying on
If you get off the chair inside the tent then your "get off objects before taking" task will move you to the floor (outside the tent),
you should do what the "Leave object" task does:
Move the player to parent location
Set property character position of player character to standing
For the recursive case you would need to call a recursive task with %Player%.Parent going to an %item% reference.
This is fairly complicated and would need another 3 tasks and a variable at least.
I will try to update your demo if I have time.
you should do what the "Leave object" task does:
Move the player to parent location
Set property character position of player character to standing
For the recursive case you would need to call a recursive task with %Player%.Parent going to an %item% reference.
This is fairly complicated and would need another 3 tasks and a variable at least.
I will try to update your demo if I have time.
Re: Bug: taking what you are standing/sitting/lying on
Not sure we have the right task actions to do it the way you described unless I am missing something. Move the player to parent location gave me errors and I'm not seeing a way to set property character position to standing without specifying what they are standing on.
Re: Bug: taking what you are standing/sitting/lying on
You need a restriction to first check that the player is not "At Location" because the parent function does not seem to work unless the player is on or in something.Move the player to parent location gave me errors
Under the "Set properties" actions select the player character and you should find the "Character position" property on the drop-down list.I'm not seeing a way to set property character position to standing without specifying what they are standing on
If it is not there then try opening and re-saving the "Player" character and try again.
I got it working for taking the tent when you are on the chair inside the tent but if you try to take the chair while it is in the tent it is hanging ADRIFT and I have no idea why yet.
Re: Bug: taking what you are standing/sitting/lying on
This seems to be working now, but will need more testing to make sure it works in all circumstances.
#File redacted#
Sitting Room
A heavy coffee table sits in the middle of the room.
Also here is a light-weight chair, a portable sitting tent and a rubber mat.
> get chair and mat
Ok, you pick up the light-weight chair and the rubber mat.
> enter tent
You step inside the portable sitting tent.
> drop mat
Ok, you put down the rubber mat.
> put chair on mat
Ok, you put the light-weight chair on top of the rubber mat.
> sit on chair
You sit on the light-weight chair.
> take tent
(Getting out of the portable sitting tent first)
Ok, you pick up the portable sitting tent.
> undo
Undone. You sit on the light-weight chair.
> take chair
(from the rubber mat)
(Getting off of the light-weight chair first)
Ok, you take the light-weight chair from the rubber mat.
#File redacted#
Sitting Room
A heavy coffee table sits in the middle of the room.
Also here is a light-weight chair, a portable sitting tent and a rubber mat.
> get chair and mat
Ok, you pick up the light-weight chair and the rubber mat.
> enter tent
You step inside the portable sitting tent.
> drop mat
Ok, you put down the rubber mat.
> put chair on mat
Ok, you put the light-weight chair on top of the rubber mat.
> sit on chair
You sit on the light-weight chair.
> take tent
(Getting out of the portable sitting tent first)
Ok, you pick up the portable sitting tent.
> undo
Undone. You sit on the light-weight chair.
> take chair
(from the rubber mat)
(Getting off of the light-weight chair first)
Ok, you take the light-weight chair from the rubber mat.
Re: Bug: taking what you are standing/sitting/lying on
I am quite impressed, Saabie, I've done recursive task setups before and know those aren't the most easiest thing to do in Adrift. I will play around with this tomorrow to see if there are any holes I can poke in it but I imagine this is already quite solid looking in implementation.
Re: Bug: taking what you are standing/sitting/lying on
OK, here is a new version with a bug fixed:
1. Any entering any container that can be closed should really move the player to a separate location to prevent them interacting with objects outside of the container.
2. It is still possible to enter a container that characters can't enter, by putting another object inside of it and getting on or in that object. This could be fixed by not letting the player get on or in an object unless it has the same parent as the player.
This version should never crash ADRIFT, but does not fix every problem with the player going in or on objects.1. Any entering any container that can be closed should really move the player to a separate location to prevent them interacting with objects outside of the container.
2. It is still possible to enter a container that characters can't enter, by putting another object inside of it and getting on or in that object. This could be fixed by not letting the player get on or in an object unless it has the same parent as the player.
- Campbell
- Site Admin
- Posts: 4734
- Joined: Sun Jun 23, 2002 12:05 pm
- Points: 0
- Location: Edinburgh, Scotland
- Contact:
Re: Bug: taking what you are standing/sitting/lying on
The Standard Library distributed with the code is online with the source here, so corrections can be made by anyone, and will be available in the next release.
ADRIFT Developer developer.