1 decade ago by ShawnSwander
Is there a way to let my server access the impact libraries so I can perform collision checks without making a separate collision map for the server?
This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact
//START HOST CHECK THE HOST CLIENT SENDS MOVE DATA FOR MOBS
hostcount=0;
if (typeof otherplayer === 'undefined') {
otherplayer = ig.game.getEntitiesByType(EntityOtherplayer);
}
for (i in otherplayer){
if (otherplayer[i].host ==true){
hostcount++;
}
}
if (hostcount==0) {
this.host=true;//if no one is hosting you host
//this.messagebox = "Host: " + hostcount;
}else{
this.host=false;
}
//END HOST CHECK