13.12.2012 Views

Re:TheAshLad - Sandbooks

Re:TheAshLad - Sandbooks

Re:TheAshLad - Sandbooks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

ump(a). r Math.floor(rand() ). if (r ). if (a ). alert(You bumped the<br />

wumpus). else. alert(The crafty wumpus dodged your arrow). if (r ).<br />

wumpus mapwumpus. else if (r ). wumpus mapwumpus. else if (r ).<br />

wumpus mapwumpus. function draw(). document.forms.box.value<br />

mappos. document.forms.box.value mappos. document.forms.box.value<br />

mappos. msg in cave pos. for (var i i. var p mapposi. if (bat p bat p).<br />

msg msg you hear bats.... if (pit p). msg msg you feel a draft.... if<br />

(wumpus p). msg msg you smell a wumpus....<br />

document.forms.msgbox.value msg. if (pos bat). alert(You've been<br />

snatched by a giant bat). pos randpos(). draw(). bat pos. while (pos bat<br />

pos wumpus bat pit). bat randpos(). else if (pos bat). alert(You've been<br />

snatched by a giant bat). pos randpos(). draw(). bat pos. while (pos bat<br />

pos wumpus bat pit). bat randpos(). else if (pos pit). alert(Uuuaaaa....<br />

You fell into a pit). initgame(). else if (pos wumpus). bump(). if (pos<br />

wumpus). alert(Gulp You've been eaten by the wumpus). initgame().<br />

function go(n). pos mapposn. draw(). function fire(n). var arrow<br />

mapposn. alert(wumpuswumpus arrowarrow). if (arrow wumpus).<br />

bump(). if (arrow wumpus). alert(You killed the wumpus). initgame().<br />

else. alert(Twang... The arrow didn't hit anything.). draw(). Hunt the<br />

wumpus. Hunt the wumpus. Instructions. You are hunting the wumpus<br />

in a completely dark cave system.. Each cavern is connected to others<br />

by tunnels. Part of the fun of the. game is figuring out how the caves<br />

are connected. In each cave you. will be told whether or not you hear<br />

bats feel a draft or smell. a wumpus.. If you feel a draft then you are<br />

next to a cavern with a pit. If you go there. you fall in the pit and die..<br />

The wumpus has suckers on its feet which prevents it from falling into<br />

a pit.. If you hear bats you are next to a cavern that contains a superbat..<br />

If you go there you get picked up and carried by the bat to another<br />

cavern.. The wumpus is very heavy which prevents the bats from<br />

grabbing it.. If you smell a wumpus you are next to a cavern that holds<br />

the wumpus.. If you enter a cavern that holds a wumpus it will either<br />

exit through. one of the tunnels or eat you.. Each turn you can choose to<br />

move or fire an arrow into an adjacent. tunnel. You do this by clicking<br />

on the fire or go buttons below the. tunnel number that you want to fire<br />

or go through.. If an arrow enters a cavern that holds a wumpus he will<br />

either exit. through one of the tunnels or stay in the room and get hit..<br />

The object is to kill the wumpus without getting killed first.. Good luck.<br />

This version of Hunt the wumpus by badger AT noemata DOT net..<br />

Adapted from a version by Sean Lane Fuller.. var pos. var wumpus. var<br />

bat. var bat. var pit. var seed .. var msg. function srand(). seed<br />

53

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!