View Single Post
  #1  
Old 03-31-2001, 07:50 AM
Grey_Mage Grey_Mage is offline
Registered User
Join Date: Mar 2001
Location: Graal
Posts: 72
Grey_Mage is on a distinguished road
Send a message via AIM to Grey_Mage Send a message via Yahoo to Grey_Mage
Question

How would you make onwall detection for this script?



if (created||timeout) {
if (this.active==1) {
//movement script
if (keydown(0)) {
playery-=0.5;
playerdir = 0;
}
if (keydown(1)) {
playerx-=0.5;
playerdir = 1;
}
if (keydown(2)) {
playery+=0.5;
playerdir = 2;
}
if (keydown(3)) {
playerx+=0.5;
playerdir = 3;
}
setani fglev,l;
disabledefmovement;
}
//Activating or deactivating script.
if (keydown(4)) {
if (this.pressed==0) {
enabledefmovement;
if (this.active==0)
this.active=1;

else

this.active=0;
this.pressed=1;

this.pressed=1;
}
}
else {
this.pressed=0;
}
timeout = 0.05;
}
__________________

Quote:
Mess with the best, die like the rest...
Reply With Quote