TAB - thinBasic Adventure Builder
Would you like to react to this message? Create an account in a few clicks or log in to continue.

TAB - thinBasic Adventure Builder

T.A.B. is an interactive fiction/text adventure program for Windows and made with thinBasic.
 
HomeLatest imagesSearchRegisterLog in
Latest topics
» Incubation pt 1
understanding carriedX I_icon_minitimeYesterday at 3:34 pm by Somsnosa

» refine player-available gender/name options
understanding carriedX I_icon_minitimeYesterday at 2:32 pm by Somsnosa

» Happy New Year 2024!
understanding carriedX I_icon_minitimeSun Dec 31, 2023 4:04 pm by catventure

» TAB Version 71
understanding carriedX I_icon_minitimeMon Aug 21, 2023 12:17 pm by catventure

» TAB Version 70
understanding carriedX I_icon_minitimeSun Oct 02, 2022 1:49 pm by catventure

» TAB Version 70
understanding carriedX I_icon_minitimeFri Sep 30, 2022 10:23 pm by catventure

» TAB Version 70
understanding carriedX I_icon_minitimeMon May 23, 2022 4:08 pm by catventure

» TAB Version 70
understanding carriedX I_icon_minitimeSat Apr 30, 2022 11:15 am by catventure

» TAB Version 70
understanding carriedX I_icon_minitimeSat Apr 23, 2022 2:32 pm by catventure


Share | 
 

 understanding carriedX

View previous topic View next topic Go down 
AuthorMessage
sandyrepope
Apprentice Adventurer


Male
Number of posts : 35
Age : 76
Adventure Points : 0
Registration date : 2008-06-10

understanding carriedX Empty
PostSubject: understanding carriedX   understanding carriedX I_icon_minitimeThu Jul 31, 2008 10:41 pm

I've looked in the language.txt file and have been trying to understand the carriedX.

Could someone explain how this is to be used?

Thanks
Sandy
Back to top Go down
catventure
Admin Adventurer
catventure

Male
Number of posts : 404
Age : 72
Location : UK
Humor : Enjoys a laugh!
Adventure Points : 77
Registration date : 2008-06-08

understanding carriedX Empty
PostSubject: Re: understanding carriedX   understanding carriedX I_icon_minitimeFri Aug 01, 2008 11:36 am

Hi Sandy,

CONDITIONS

carriedX
notcarrX

Check if a particular object is carried by player or not carried by player

X = object number

Object 5 = a sword

Character 1 = a creature

Example usage:

attack creature with sword#charpresent1#carried5[acts]cmessYou swing the sword and swiftly decapitate the creature. It is dead.#charloc1=0#else#charpresent1#notcarr5[acts]cmessBut you aren't holding a sword![end]

This translates as:
IF character 1 (the creature) is present AND the sword is carried THEN kill the creature and remove it from game (set its location to 0) ELSE IF the creature is here but the sword is not carried THEN tell the player via a cmess action...

There are also companion commands:

objlocn1=carried - is objn1 carried?
objlocn2=carried
objlocn1=notcarried - is objn1 not carried?
objlocn2=notcarried

Here is a further example which could follow the above one:

attack %charn1% with %objn2%#charpresentn1#objlocn2=carried[acts]cmessYou attack %charname1% with the %objn2%. It didn't seem to have any effect...#else#charpresentn1#objlocn2=notcarried[acts]cmessBut you aren't holding a %objn2%![end]

This will trigger if the player tries to attack ANY valid character with ANY valid object providing the character is present and will produce a different reply depending on if the object in question is carried or not carried.

catventure
Back to top Go down
https://adventure.forumotion.com
 

understanding carriedX

View previous topic View next topic Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
TAB - thinBasic Adventure Builder :: TAB FORUMS :: General Forum-
Jump to: