Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Admission fee


dao
 Share

Recommended Posts

i want it so its a block and when you run into the block it says Would you like to pay 50g to enter?
and a yes no button. if no its still blocked if yes you walk through and it takes 50g. xD
Link to comment
Share on other sites

I'll explain how to do it.
Things you would need: The PlayerPrompt sub (if it still works), which is in the main.txt (you'll be editing that, so read a tutorial on how to use it).
The BlockPlayer sub (found in the Script Index)
Godlord's Inventory Script (also found in the Script Index) for the CanTake sub.

Here is a algorithm in a rough version of pseudocode on how it would go…

First, the scripted tile:
Call the Prompt(index, "Would you like to pay 50g to enter?", #)

Then in your PlayerPrompt sub, use the under case # (for yes):
If cantake 50g Then
  take 50g
Else
  print: "You don't have enough gold"
  Block the player
End If
Then, for the no section of the prompt for case #, just block the player.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...