View Single Post
  #21  
Old 12-25-2012, 12:13 PM
Gunderak Gunderak is offline
Coder
Gunderak's Avatar
Join Date: Jun 2011
Location: Australia
Posts: 795
Gunderak is on a distinguished road
Quote:
Originally Posted by callimuc View Post
so you expect him to write down all blocking tiles while he could do a simple onwall(), onwall2() or tiletype() check?



things you should fix:
PHP Code:
setani("ani"params); //proper gs2; if you dont have params make it NULL (params part)

this.indodge boolean//boolean is true or false; should be used instead of using (un)set

for (temp.0temp.4temp.i++) {
  if (
onwall2(player.x+0.5player.y+1+122)) continue;
  
//onwall2(x, y, width, height);
  //at the player.y part i added two +1 because the first is to have it go down to the "default" block check and the
  //2nd one is for the new y position, personal reference of doing it like this; should be fixed with '-' or at the
  //'player.x' parts when you are using it in other directions
  //continue should make it leave the for() loop when you are on the wall (regarding the check)

  
player.+= 1;
  
sleep(.1);

Whatever.
There are many ways of achieving the same thing.
I was simply providing one.
__________________

Gund for president.

Remote PM {P*}x (Graal813044) from eraiphone -> Stefan: I hav 1 qustion
*Gunderak: he hav 1
*Gunderak: qustion
Reply With Quote