View Single Post
Old 02-09-2010, 11:11 PM
DrakilorP2P DrakilorP2P is offline
Registered User
DrakilorP2P's Avatar
Join Date: Apr 2006
Posts: 755
DrakilorP2P is just really niceDrakilorP2P is just really nice
Not sure about the weapon script, but I found some errors in the gani script after trying a few things.

PHP Code:
//onCreated doesn't seem to work when you're putting ganis in player.attr[].
function onPlayerEnters() {
with (findimg(200)) { //There was a missing parenthesis here.
attachtoowner true//Follow the player.
emitter.delaymin 0.01;
emitter.delaymax 0.01;
emitter.nrofparticles 1;
emitter.particle.image "g4_animation_fire.gif";
emitter.particle.alpha 0.99;
emitter.particle.lifetime 0.5;
emitter.particle.speed 10;
emitter.particle.spin 2; 1; .4; .4;
  } 2;

onTimeout() {
//showimg(200); //What?
if( timevar2) {
this.fireangles= {-4.7,-3.1,-1.6,0};
//Doesn't do anything I think.
    //x = player.x;
    //y = player.y;
    //Shorter version of the below.
findimg(200).emitter.particle.angle this.fireangles[player.dir]+random(-.5,.5);

/*for(i=0;i<4;i++) {
      if(player.dir == i) {
      findimg(200).emitter.particle.angle = this.fireangles[i]+random(-.5,.5);
//} //Extra bracket?

Not sure why you're making it stop updating after 2 seconds, since onClearFire seems to be doing that just fine.
Reply With Quote