View Single Post
  #9  
Old 06-09-2014, 07:35 PM
blackbeltben blackbeltben is offline
Registered User
Join Date: Aug 2011
Posts: 83
blackbeltben is on a distinguished road
Quote:
Originally Posted by Jakov_the_Jakovasaur View Post
i just realised that the first tile should be 0x0 rather than 1x1 as mentioned in your first post, 1x1 probably isnt even valid

should definitely work if you do:

PHP Code:
if (tiles[player.1.5player.2] == 0
taking a closer look at your snippet of code in the first post, its worth mentioning that it should be something like this if it isnt already:

PHP Code:
//#CLIENTSIDE
function onCreated()
  
this.onTimeout();

function 
onTimeout() {
  if (
tiles[player.1.5player.2] == 0) {
    
player.chat "Found Tile!";
  }
  
this.setTimer(0.05);

if something doesnt work as expected then you can also attempt to debug it like so:

PHP Code:
player.chat tiles[player.1.5player.2]; 


Yay it works

But can you explain how you did get 17 though? How do I calculate what tiles are equal to what value?
Reply With Quote