Just Adventure News : News: Video Games: The Movie Press Release: Indie Narrative / Strategy Game 7 Grand Steps Will Release June 7 for PC and Mac Gold: The Incredible Adventures of Van Helsing Demo: Jack Haunt: Old Haunting Grounds Alpha Demo Released Game: Might And Delight Presents "Shelter" Early Gameplay Footage Press Release: Legendary Monsters Are Invading Age of Conan Press Release: New Settler and Scientist Path content for WildStar News: Towdie on Kickstarter News: H.P. Lovecraft's Dagon Press Release: Makers of Son of Nor PROVE mind control is genuine
Home - Forum Home
Welcome Guest, please Login or Register!
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register or login before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Topic: Need basic help with Inform 7

    Page 1

All Forums : [Adventure Games Forum] : Interactive Fiction > Need basic help with Inform 7
8 SEP 2008 at 10:51am

kingwtch

Intergalactic Janitor
Intergalactic Janitor



Posts : 1
Joined: 8 SEP 2008

Status : Online
Hey I've got a project due for school in 2 weeks where I have to create an IF in Inform 7.  I have a good idea what the story is I want to do, but I'm having a lot of trouble figuring out basic commands in Inform 7.  So, here's my questions:

How would you write a statement that prevents the user from leaving a room unless he has picked up certain items?

The closest I could think would be to use something along the lines of

Instead of leaving the room, say "You haven't gathered everything you need."

The problem with this is that you are forever trapped in the room and can't escape even with the items you need.

The other question I have is for using objects.  I have an elevator button in the hall.  The user will want to press it.  I do not want them to press it though, as it will lead them nowhere.  How can I tell inform I want it to say "
on't push that button." when the user attempts to push it?

This seems like an instead statement as well, but there is no command for pushing an object I place in a room called an elevator button.  For example,

Instead of pressing the elevator button, say "
on't push that."

does not work because Inform doesn't understand the action of pushing the button.

Thanks for any help, and time is a factor here for me so I would appreciate quick responses.

Profile Search


23 SEP 2008 at 4:11pm

Ewarwoowar

Intergalactic Janitor
Intergalactic Janitor



Posts : 8
Joined: 25 JUL 2008

Status : Online
Originally Posted By kingwtch (8 SEP 2008 10:51am)
How would you write a statement that prevents the user from leaving a room unless he has picked up certain items?


Try this:


"The Laboratory " by PaulDV

The player is in a room called The Lab.
North of the Lab is Out the Back.

In the Lab is a stethoscope, some mysterious goo and a bunsen burner.

Before going from the Lab while the stethoscope is in the Lab:
     if the player is not carrying the stethoscope:
           say "You can't go just yet!  You seem to have left something important behind..." instead.


Regards,
Paul.
[url=www.mudii.co.uk][img]http://www.logicshopltd.co.uk/blbanner.gif[/img][/url]&&[url=http://www.shopjoy.co.uk/free-money/?ref=pauldv]FREE MONEY for YOU![/url]

Profile Search
23 SEP 2008 at 4:45pm

Ewarwoowar

Intergalactic Janitor
Intergalactic Janitor



Posts : 8
Joined: 25 JUL 2008

Status : Online
Originally Posted By kingwtch (8 SEP 2008 10:51am)
The other question I have is for using objects.  I have an elevator button in the hall.  The user will want to press it.  I do not want them to press it though, as it will lead them nowhere.  How can I tell inform I want it to say "
on't push that button." when the user attempts to push it?

This seems like an instead statement as well, but there is no command for pushing an object I place in a room called an elevator button.  For example,

Instead of pressing the elevator button, say "
on't push that."

does not work because Inform doesn't understand the action of pushing the button.


Hmm... Looking at the actions built into I7, both press and push (they are considered the same thing) are listed.  I think you may have something else amiss, because this works for me:


"The Laboratory " by PaulDV

There is a room called The Lab. "This is a somewhat stark laboratory. A doorway to the north leads to a room out the back.  On the wall next to the doorway is a button with a label which reads 'Do Not Push'".
North of the Lab is Out the Back.

The button is scenery in the lab. "It[']s a button - the kind you push, not the kind you do fasten thing with - and appears very worn and probably doesn[']t work any more.  It[']s function is unclear, but the sign makes it perfectly clear that it shouldn[']t be pushed."

Instead of pushing the button:
     say "
on[']t push that!  The sign says not to...".


Regards,
Paul.
[url=www.mudii.co.uk][img]http://www.logicshopltd.co.uk/blbanner.gif[/img][/url]&&[url=http://www.shopjoy.co.uk/free-money/?ref=pauldv]FREE MONEY for YOU![/url]

Profile Search
All Forums : [Adventure Games Forum] : Interactive Fiction > Need basic help with Inform 7

    Page 1

Jump to:
0 Members Subscribed To This Topic