Thread: Light Switch
View Single Post
  #1  
Old 11-19-2006, 09:03 AM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
Light Switch

HTML Code:
//#CLIENTSIDE
function onCreated()
{
  seteffect(0, 0, 0, 0.65);
  this.lightOff = true;
}
function onPlayerTouchsMe()
{
  this.lightOff = !this.lightOff;
  temp.curEffect = (this.lightOff? {0, 0, 0, 0.65}: {0, 0, 0, 0.85});
  seteffect(temp.curEffect[0], temp.curEffect[1], temp.curEffect[2], temp.curEffect[3]);
}
Made it for era, change the temp.curEffect value's for the different level effects. Simple yet fun
__________________
Reply With Quote