C
Carter Davis
There is probably an easy answer to this, but I need help. Recently I've
started making a text-based adventure game in Ruby, and so far it's
going very well. One problem I'm having, though, is that whenever I use
puts to output a string, the string is in quotes. Is there any way in
which I can disable this?
Also, I can't seem to get string literals to work. I'll type in, for
example,
p "You see a glass cup, and there is a door NORTH.\n There is also a
long hallway SOUTH."
And it will output the exact same - when I run the code, it says:
"You see a glass cup, and there is a door NORTH.\n There is also a long
hallway SOUTH."
I have no idea how to fix said problems...can anyone help me?
Thanks,
Jearb
started making a text-based adventure game in Ruby, and so far it's
going very well. One problem I'm having, though, is that whenever I use
puts to output a string, the string is in quotes. Is there any way in
which I can disable this?
Also, I can't seem to get string literals to work. I'll type in, for
example,
p "You see a glass cup, and there is a door NORTH.\n There is also a
long hallway SOUTH."
And it will output the exact same - when I run the code, it says:
"You see a glass cup, and there is a door NORTH.\n There is also a long
hallway SOUTH."
I have no idea how to fix said problems...can anyone help me?
Thanks,
Jearb