TAB - thinBasic Adventure Builder

T.A.B. is an interactive fiction/text adventure program for Windows and made with thinBasic.
 
HomeFAQSearchUsergroupsRegisterLog in
Latest topics
» TAB Version 66 Available
Mon Sep 26, 2016 12:02 pm by catventure

» TAB Version 65 Available
Mon Feb 23, 2015 12:04 pm by catventure

» Incubation pt 1
Wed Apr 24, 2013 9:24 am by Kabrinski

» Charecter movements - doors
Wed Mar 20, 2013 2:55 pm by garethfx

» Member feedback on game planning
Sun Mar 03, 2013 1:47 pm by garethfx

» Still alive - just!
Thu Feb 28, 2013 11:34 am by catventure

» TAB 64 crashes ...
Mon Aug 20, 2012 11:31 am by acko

» Idea on addition to object being container
Sat Aug 18, 2012 3:49 pm by catventure

» sizex=y action ...
Thu Aug 09, 2012 11:29 am by catventure


Share | 
 

 Responses

View previous topic View next topic Go down 
AuthorMessage
Kaneb1997
Novice Adventurer


Number of posts : 1
Adventure Points : 1
Registration date : 2010-09-25

PostSubject: Responses   Sun Sep 26, 2010 8:05 pm

Hey all,im new to this whole thing (only started yesterday) so can you please be noob friendly.

My problem is that im want to make a guy that when you talk to him he says go get somthing,then when you talk to him again is does a check to see if u have the item in ur inv,then if u do it removes it and you get a reward,in this case a Knife.

So ive got
[start]talk to weapon dealer#charpresent3#[acts]cmess Weapon Dealer: Hey mate,Sorry but I dont have any weapons in,some idiot stole them.Tell you what if you get me a stick ill give you a Knife.Show me the stick once you get 1.#flag1=1#[end]

then ive got

[start]talk to weapon dealer#charpresent3#flag1=1#check for stick#[acts]cmess Weapon Dealer: So I see you have the stick,ill just take that from you and here is the Knife.#remove stick#add knife[end]

Back to top Go down
View user profile
catventure
Admin Adventurer
avatar

Male
Number of posts : 376
Age : 64
Location : UK
Humor : Enjoys a laugh!
Adventure Points : 52
Registration date : 2008-06-08

PostSubject: Re: Responses   Mon Sep 27, 2010 8:12 am

Kaneb1997 wrote:
Hey all,im new to this whole thing (only started yesterday) so can you please be noob friendly.

My problem is that im want to make a guy that when you talk to him he says go get somthing,then when you talk to him again is does a check to see if u have the item in ur inv,then if u do it removes it and you get a reward,in this case a Knife.

So ive got
[start]talk to weapon dealer#charpresent3#[acts]cmess Weapon Dealer: Hey mate,Sorry but I dont have any weapons in,some idiot stole them.Tell you what if you get me a stick ill give you a Knife.Show me the stick once you get 1.#flag1=1#[end]

then ive got

[start]talk to weapon dealer#charpresent3#flag1=1#check for stick#[acts]cmess Weapon Dealer: So I see you have the stick,ill just take that from you and here is the Knife.#remove stick#add knife[end]


Hi Kaneb1997,

Welcome to the TAB IF Community.

You are on the right track alright. Where you have put "check for stick" you need to use one of the object check CONDITION eg:
#objlocX=501#
or
#carriedX#
(where X is the object number of the stick; checks player carried inventory to see if that object is being carried)

Where you have put "remove stick" you need to use an object manipulation
ACTION such as:
#destroyX#
or
#objlocX=0#
(where X is object number of stick; removes stick from game)

As "weapon dealer" is 2 words you may need to change it to "dealer" in the Character NOUN field in the Character Editor...
/dealer/

and add "weapon" to the deletions vocabulary...

Where you have put #add knife# in the entry you agian use one of the object ACTIONS eg:
#objlocX=501#
(where X is the object number of the KNIFE... puts the object to the player's carried inventory)

You may also need to check that flag1=0 and amend it to hold a value of 2 when the knife has been handed over...

So your entries would look something like this:

[start]talk to dealer#charpresent3#flag1=0[acts]cmessWeapon Dealer: "Hey mate, Sorry but I dont have any weapons in. Some idiot stole them. Tell you what if you get me a stick I'll give you a Knife. Show me the stick once you get one.#flag1=1[end]

[start]talk to dealer#charpresent3#flag1=1#carriedX[acts]cmessWeapon Dealer: "So I see you have the stick. I'll just take that from you and here is the knife.#destroyX#objlocX=501#flag1=2[end]

[start]talk to dealer#charpresent3#flag1=2[acts]cmessWeapon Dealer: "I have nothing further to say or tell you!"[end]

The third entry triggers if they talk to the dealer AFTER he has given up the knife.. (flag1=2)

Hope this helps.

Let me know, anyway.

Regards,
catventure.

_________________
http://tab.thinbasic.com ; Home of the TAB I.F. project.
Back to top Go down
View user profile http://adventure.rpgdynasty.com
 

Responses

View previous topic View next topic Back to top 

 Similar topics

+
Page 1 of 1

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