Permalink
Browse files

newip

  • Loading branch information...
ericz committed Feb 18, 2012
1 parent 198b2cd commit 51c6cc354f01a95cd641824832e364f26a2dbd8e
Showing with 12 additions and 11 deletions.
  1. +1 −1 admin/public/js/control.js
  2. +3 −3 admin/public/js/display.js
  3. +3 −3 admin/public/js/index.js
  4. +5 −4 physics.js
@@ -19,7 +19,7 @@ $(function(){
}
});
- bridge = new Bridge({url: 'http://136.152.39.187:8091/bridge'});
+ bridge = new Bridge({url: 'http://136.152.37.120:8091/bridge'});
bridge.ready(function(){
bridge.getService('physics', function(obj){physics = obj});
});
@@ -28,11 +28,11 @@ var draw = function( drawables) {
var translate;
window.onload = function() {
- var bridge = new Bridge({url: "http://136.152.39.187:8091/bridge"});
+ var bridge = new Bridge({url: "http://136.152.37.120:8091/bridge"});
console.log("ONLOAD");
bridge.ready(function() {
- bridge.joinChannel('shot4', { draw: draw}, function(){});
- bridge.getService("admin2", function(x) {
+ bridge.joinChannel('shot3', { draw: draw}, function(){});
+ bridge.getService("admin", function(x) {
x.addRect($(window).width(), $(window).height(), function(o, tl) {
translate = tl;
orientation = o;
View
@@ -65,10 +65,10 @@ var findCenterOffset = function(xoff, yoff) {
$(function(){
- bridge = new Bridge({url: 'http://136.152.39.187:8091/bridge'});
+ bridge = new Bridge({url: 'http://136.152.37.120:8091/bridge'});
bridge.ready(function(){
- bridge.publishService('admin2', {addRect: addRect});
- bridge.getService('physics2', function(obj){physics = obj});
+ bridge.publishService('admin', {addRect: addRect});
+ bridge.getService('physics', function(obj){physics = obj});
});
});
View
@@ -1,5 +1,5 @@
var Bridge = require('./bridge').Bridge;
-var bridge = new Bridge({host:'136.152.39.187'});
+var bridge = new Bridge({host:'136.152.37.120 '});
var ball = {x:120,y:120,radius:20};
var paddle1 = {x1:50,y1:50,x2:90,y2:60};
var paddle2 = {x1:50,y1:50,x2:90,y2:70};
@@ -260,8 +260,9 @@ util = {
}
bridge.ready(function(){
console.log('bridge');
- bridge.joinChannel('shot4',{draw:function(){}},function(){});
- bridge.getChannel('shot4', function(obj) { shot3 = obj;shot3.draw('asd') });
- bridge.publishService('physics2', physics, function() {console.log('physics2')});
+ bridge.joinChannel('shot3',{draw:function(){}},function(){
+ bridge.getChannel('shot3', function(obj) { shot3 = obj;});
+ });
+ bridge.publishService('physics', physics, function() {console.log('physics')});
});

0 comments on commit 51c6cc3

Please sign in to comment.