Virtual Economies: Design and Analysis