Skip to content

Instantly share code, notes, and snippets.

@NTaylorMullen
Created October 27, 2013 01:11
Show Gist options
  • Save NTaylorMullen/7176744 to your computer and use it in GitHub Desktop.
Save NTaylorMullen/7176744 to your computer and use it in GitHub Desktop.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Demo;
using EndGate.Server;
using Microsoft.AspNet.SignalR;
namespace DryRunDemo
{
public class MyGame : Game
{
public UserManager<Player> UserManager = new UserManager<Player>();
public override void Update(GameTime gameTime)
{
foreach(var user in UserManager.Users)
{
user.Update(gameTime);
}
}
public override void Push()
{
GlobalHost.ConnectionManager.GetHubContext<GameHub>().Clients.All.update(UserManager.Users);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment