Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 07-14-2007, 04:10 AM
theHAWKER theHAWKER is offline
**FLIP OUT**
theHAWKER's Avatar
Join Date: Mar 2006
Location: canada, vancouver
Posts: 768
theHAWKER is an unknown quantity at this point
Question script help ;D

why isn't this working??
PHP Code:
function onCreated(){
this.on false;
}
function 
onWeaponFired(){
if (
this.on false){
this.on true;
}
if (
this.on true){
this.on false;
}
}
function 
onCreated(){
setTimer(.1);
}
function 
onTimeout(){
if (
this.on true){
player.alpha 50;
}
if (
this.on false){
player.alpha 100;
}
setTimer(.1);

__________________
**FLIP OUT**
Reply With Quote
  #2  
Old 07-14-2007, 04:26 AM
JkWhoSaysNi JkWhoSaysNi is offline
Ruler of the graalaxy
Join Date: Feb 2005
Location: Great Britain
Posts: 488
JkWhoSaysNi is on a distinguished road
Send a message via ICQ to JkWhoSaysNi
Because you're using = as comparison, you have 2 onCreated's
Also, your script is 10x longer than it needs to be

edit: Why are you even using a timeout?

PHP Code:
function onCreated(){
this.on false;
}
function 
onWeaponFired(){
this.on = !this.on;
player.alpha = (this.on) ? 50 100;

__________________

Coming soon (Hopefully:P)
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 02:47 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.