Special

Introducing the “Welcome to Xojo” Bundle!

New to Xojo and looking for guidance? We've put together a terrific bundle to welcome you! Xojo Bundle

This bundle includes six back issues of the magazine -- all of year 21 in printed book and digital formats -- plus a one-year subscription (beginning with 22.1) so you'll be learning all about Xojo for the next year. It's the perfect way to get started programming with Xojo. And you save as much as $35 over the non-bundle price!

This offer is only available for a limited time as supplies are limited, so hurry today and order this special bundle before the offer goes away!

Article Preview


Buy Now

Issue 3.4

COLUMN

From Scratch: Networked TanGram

Issue: 3.4 (March/April 2005)
Author: William Leshner
Author Bio: William Leshner has been programming for twenty-five years and programming Macs for fifteen. He has spent a good deal of the last several years building REALbasic applications, utilities, and plugins, including KidzMail, KidzLog, and SQLitePluginPro. You can also check out his REALbasic weblog at http://www.rbgazette.com/.
Article Description: No description available.
Article Length (in bytes): 12,348
Starting Page Number: 40
Article Number: 3418
Resource File(s):

Download Icon 3418.zip Updated: 2005-03-15 19:48:51

Related Web Link(s):

http://www.rbgazette.com/

Excerpt of article text...

Introduction

This is the first of three bonus articles about designing and building TanGram, a game where players drag around polygonal shapes and arrange them to make pictures. As you may recall, we finished up the TanGram application in the last article. You may be wondering what else there is to do. Among the possible TanGram extensions we could implement, I have decided that adding networked play would be the most interesting. You might not think that TanGram is the best candidate for networked play, but if we design and implement the networked play correctly, it may turn out to be a lot of fun. And it gives us a chance to experience just how easy it is to build simple networked games in REALbasic.

The Plan

I envision the networked version of TanGram to be a game that can be played on multiple computers connected to the same local network. When TanGram launches, it will discover the other players on the network and immediately join their in-progress game. Each copy of TanGram will show a list of all the players currently playing. If a new player joins the game, every other player will know it immediately. When a player moves a piece of the puzzle, every other player will see the same move in their own TanGram. Also, there will be a chat area so that players can chat with each other as they play. For extra credit, and if we have time, we will implement the ability to send private messages to individual players.

...End of Excerpt. Please purchase the magazine to read the full article.