From: "Thomas B." Date: 2008-08-29T06:07:25+09:00 Subject: Re: Use a string as a method call Chris Bailey wrote: > send $cmd_list[input] > cmd_list = { > 'north' => 'do_north' > 'south' => 'do_south' > 'n' => 'do_north' > 's' => 'do_south' > 'look' => 'do_look' > } The variable names don't agree but I suppose it's a typo in the post? Well, what are you trying to do? If you want to increment or decrement $PLROBJ.xcoord, you must say $PLROBJ.xcoord+=1 or $PLROBJ.xcoord-=1. What happens now, the variable $PLROBJ.xcoord is incremented or decremented by the result of showMap, like in $PLROBJ.xcoord-=showMap(), and showMap probably returns nil. TPR -- Posted via http://www.ruby-forum.com/.