Bug in Combined Library 4.1: Task "Remove before drop"

Announcements about ADRIFT, this Forum, the website and anything else relevant.

For more information visit the main ADRIFT Website
Post Reply
User avatar
Denk
Posts: 1002
Joined: Mon Feb 22, 2016 6:21 pm
Points: 346
Location: Hjørring, Denmark

Bug in Combined Library 4.1: Task "Remove before drop"

Post by Denk »

Hi,

The Combined Library 4.0 has just been released:
EDIT: There have been some bugfixes since 4.0 and 4.1 so the newest version is "version 4.2" and can be found here:
https://www.adrift.co/game/1642

Several new verbs as well as the property TransparentScope have been introduced. So the player can now "see" objects within transparent containers.

NB: Transparency doesn't work well if you put the player inside a closed container object.


Changes since last version:

1. Transparent containers have been implemented. The hard-coded restrictions SEEN and VISIBLE cannot be changed, so a new object property "TransparentScope" has been created. Read "Transparency Instructions" in the "Transparent Containers"-folder in the Standard Library. to use it correctly.
NB: About half of all library tasks were modified to implement transparent containers. So if you experience some weird behaviour please let me know (Denk on ADRIFT forum).

2. Unticked "prevent this task from being inherited" in the tasks "unlock objects (lazy)" and "unlock objects (lazy)" though it is normally sufficient to override the "lock/unlock first object with second object"-tasks.

3. Add PLACE to all PUT tasks. Specifically for the drop task, it now understands: [place/put] %objects% on {the} [ground/floor]

4. Include the optional fake ending to avoid undo-problems (also save/restore problems)

5. The task "Look in object" had no restrictions! Fixed.

6. The task "# Auto-unlock object with key" missed some restrictions. It only mattered if you had ticked the Player-property "Automatically unlock objects if you have the proper key and try to open them". Fixed.

7. The simple but very old "score-percentage"-bug has finally been fixed.

8. "Below" added to the "Look under object"-task.

9. Make ADRIFT ask "Get what?" instead of "Get who?" if you only type "get". The question can be responded (built-in feature of ADRIFT if used correctly). The same with "take".

10. Make ADRIFT ask "Fire what?" if the player only types "Fire". Can be responded (built-in feature of ADRIFT if used correctly).

11. Add a "move object"-task to the Push and Pull folder.

12.1. New synonyms for attack: fight, murder, punch
12.2. New synonym for close: shut
12.3. New synonyms for drop %object%: discard %object%
12.4. New synonym for pull: drag
12.5. New synonyms for "put objects in others": insert
12.6. New synonyms for rub: scrub, wipe
12.7. New synonym for smell: sniff
12.8. New synonyms for turn %object%: spin, rotate, twist
...and remove restriction that requires that you are holding the object.
12.10 Add a "break %object%"-task. Synonyms: destroy, smash, crack

13.1. New task: Throw object at/on %character%, synonym: toss
13.2. New task: Throw %object1% at/on/onto %object2%, synonym: toss
13.3. New task: fix throw at
13.4. New task: Throw object1% in/into %object2%, synonym: toss

14.1. New task: tie/fasten/attach %object1% with/using %object2%
14.2. New task: untie/undo/detach/unfasten %object%
14.3. Fix tie-tasks

15.1. New task: Light %object%
15.2. New task: Extinguish task

16.1. New task: Listen to %object%
16.2. New task: Listen to %character%
16.3. Fix listen tasks
16.4. Change existing task "listen * " to just "listen"

17.1. Search %object% will call "look in %object%" if the object is a container.
17.2. New task: search character
17.3. Fix search

18. New task: talk to %character% - Synonyms: speak, answer

19. SCREW and UNSCREW should not be synonyms for TURN. Instead I will make a separate task for SCREW and another for UNSCREW.

20. A few priorities fixed so all priority numbers in the library are above 40000 except for one task in the "fake ending" folder. That task has priority one. Thus you know that priorities in the library will not prevent your own tasks from running if you use priority numbers less than 40000. NB: Normally when you override a library task, the priority of your task is not important. The priority number does not need to be lower than the task you are overriding. However, there are a few specific tasks in the library. If you override the same tasks as those specific tasks, your task is competing with these specific tasks. Thus your task must have higher priority (i.e. lower priority number) than those specific library tasks. This may give the impression that you must have higher priority than the task you are overriding but this is not the case. The problem is the other specific tasks. You can get the same problem if you create two specific tasks that override the same general task.
Last edited by Denk on Thu Oct 14, 2021 3:58 pm, edited 9 times in total.
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
User avatar
Denk
Posts: 1002
Joined: Mon Feb 22, 2016 6:21 pm
Points: 346
Location: Hjørring, Denmark

Re: Combined Library 4 has just been released

Post by Denk »

I am considering making an update (version 4.1) because Larry found some problems and I also noticed that the priorities are very sensitive.

Please let me know the problems you find ASAP if there are some, so they can all be included in the same update.

I knew that changing one task priority number would change priorities of other tasks, but at least I expected the priority order to be fixed. But the order is not fixed - sometimes priorities that were slightly lower than another task ends up having the same priority which ruins the behaviour of the library.

Example:
I just created a new general task with priority number 50100, which ruined the priority order in the "Look and examine"-folder though the affected priorities were in the range 50005-50007!

So I will try to mess around with priorities until they seem more stable. If any of you have some advice on how to modify priorities safely, please let me know - thanks.
:Thanks:
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
User avatar
Lazzah
Moderator
Posts: 2524
Joined: Thu Mar 31, 2011 5:54 am
Points: 100
Location: Clacton-on-Sea, Essex
Contact:

Re: Combined Library 4 has just been released

Post by Lazzah »

When I am creating an adventure with ADRIFT, whenever I create a specific task I have got into the habit of first of all changing it to a general task. I then open the Advanced Tab, tick the "Prevent this task from being inherited" box and, most importantly, I delete one number from the Task Priority, usually the highest number after the first one, e.g. if the number is 40972 I delete the 9. This might not be 'best practise' but it has always worked for me.
Visit "Larry's ADRIFT Text Adventures" at http://LarrysAdriftTextAdventures.co.uk
User avatar
Denk
Posts: 1002
Joined: Mon Feb 22, 2016 6:21 pm
Points: 346
Location: Hjørring, Denmark

Re: Combined Library 4 has just been released

Post by Denk »

Lazzah wrote: Mon Sep 27, 2021 10:46 am When I am creating an adventure with ADRIFT, whenever I create a specific task I have got into the habit of first of all changing it to a general task. I then open the Advanced Tab, tick the "Prevent this task from being inherited" box and, most importantly, I delete one number from the Task Priority, usually the highest number after the first one, e.g. if the number is 40972 I delete the 9. This might not be 'best practise' but it has always worked for me.
That is a good idea. So you ensure all new tasks are below 10000 and thus your own tasks are never disturbed by tasks in the standard library.

My main problem was that I need a bigger gap between tasks. Otherwise, tasks that have almost the same priority were suddenly given the same priority when I created a completely different task with a very different priority. If this happens, those tasks that were meant to have different priorities will not work as intended.

So today I have just renumbered all priorities in the Combined Library in order to avoid this from happening. So most task priorities are 3 to 5 smaller or bigger than "adjacent" priorities.

Now, all priorities in the library are between 52000 and 57000. However, I was surprised to see how much the priorities changed when I was done. The first priorities I set were automatically changed whenever I changed the priorities of other tasks. The first priorities I set were changed almost 100 places by ADRIFT when I was done.

Another thing I just learned:
When you start working on a game, you cannot make priorities with big numbers. For instance, with Combined Lib. v4.0 you can to begin with not make priorities greater than 50126. If you create a task like that, then the next task can be 50127 etc.

But I wanted it to be more flexible, so for instance a group of tasks could have priorities between 51000 and 52000 (fictive example). But I couldn't go higher than approximately 50126. I then created a folder in ADRIFT and made a test task in that folder and exported the folder as an amf-file(module). I could then change the priority of the task in the amf-file using notepad. I set it to 100000. Then I imported the modified amf-file so I had a task with priority 100000. Then I could freely choose any priority number up to 100000. Good to know :)

So I think I have a better idea now of priorities.

BTW, thanks to P/o Prune for proposing making distinct priority groups, for instance "uncategorized tasks" are now between 52800 and 53200 in the upcoming v4.1.

I still have to implement the changes proposed by Lazzah, and any bugs people might find in the meantime :)
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
User avatar
Denk
Posts: 1002
Joined: Mon Feb 22, 2016 6:21 pm
Points: 346
Location: Hjørring, Denmark

Re: Combined Library 4.1 has just been released

Post by Denk »

The changes have been implemented, so here is Combined Library 4.1:

EDIT: There have been some bugfixes since 4.0 and 4.1 so the newest version is "version 4.2". It can be found here:
https://www.adrift.co/game/1642

Details:
************************
READ ME FOR Release 4.1:
************************
Changes since last release (4.0):
1. Changed all(!) priorities to have more space between priorities, otherwise the library was unstable to new tasks. Library tasks have priorities from 52000-57000 (see details below: *).
1. Fixed typos
2. added task "tie object to object"
3. split "throw object AT/ON/ONTO object" into different tasks.
4. Added a few more synonyms for throw (chuck, lob) and added "towards" as a synonym for "at" in throw tasks
5. Made corresponding "throw object on character task" and a necessary fix task (needed when characters and objects have the same noun).

*: Priority Details:
- Uncategorized tasks: 52800-53200
- Give, take and drop: 53500-53700
- Throw: 53700-53900
- Tie and untie: 53900-54000
- Nautical Directions: 54000-54130 [These 3 categories...
- Player Movement: 54140-54180 have common..........
- Character position: 54190-54400 commands.............]
- Push, pull, move: 54400-54500
- Conversation: 54700-54900
- Open and Close: 54900-55100
- Look & Examine: 55300-55500
- Wear and Remove: 55500-55600
- Eat and Drink: 55500-55600
- Attacking: 55700-55900
- On, off: 55800-56000
- Shoot and Fire: 55900-56100
- Fake Ending: 56100-56200 (and one task has priority 1)
- Transparent Containers: 56300-56400
Last edited by Denk on Thu Oct 14, 2021 3:59 pm, edited 2 times in total.
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
User avatar
Denk
Posts: 1002
Joined: Mon Feb 22, 2016 6:21 pm
Points: 346
Location: Hjørring, Denmark

Bug in Combined Library 4.1: Task "Remove before drop"

Post by Denk »

Hi,

I discovered a a bug in the restrictions of task "Remove before drop"in the folder "Give, take and drop".

I have fixed the restrictions (including restriction messages) in that task and here is a fixed version:
EDIT: The new official version 4.2 is now available here: https://www.adrift.co/game/1642

If you have already begun work on a game, the easiest way to fix it is probably to open the attached taf-file (please save a backup of your game before trying and disable all libraries). Then go and open the task "Remove before drop". Copy all restrictions in that task, then open your game and find the same task in your game. Delete all restrictions and paste the restrictions you just copied. Then everything should work allright. NB: You cannot copy anything between two instances of the Developer. Thus, first you must open the lib-file, copy what you need and then open you game without shutting down the Developer.

I don't plan to make an official release very soon, as I would like to look at the fact, that ADRIFT regards objects as held by the player when they are inside a held container. This is not the case if the container is worn. If you would like me to consider something related to that, please let me know in the thread: https://forum.adrift.co/viewtopic.php?f ... 17#p110217
----------------------------------------------------------------------
The Bash Saga:
1. The Dragon Diamond 2. The Way Home 3. Stone of Wisdom
----------------------------------------------------------------------
Post Reply