Graal Forums  

Go Back   Graal Forums > Development Forums > Level Design
FAQ Members List Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-22-2002, 12:58 AM
amonrabr amonrabr is offline
Scripter
Join Date: Nov 2001
Location: Brazil
Posts: 374
amonrabr is on a distinguished road
Quote:
Originally posted by Falcor
It is wise to set constants in your scripts so you know WHY you have a number where you have it...

such as

if(created) pi = 3.1415;

so you know instead of having to type 3.1415 every time you want to use pi, just type pi its far more understandable.
And ammon, Why us % (mod) in that way? Itlowers the general efficiency of the script, thx kai for pointing this out...

Its not supose to be used in that way. rather in an if statement.

you sghould just do if(this.a > blah) this.a = 0;

my nick is Amon = þ" Lol..
and the "%" is a way that I found to use it, u can test, it will work fine.

I dont like to use " if(this.a > blah)" because I think its big, so I like to use some other way as "this.a=this.a<blah?this.a+=.1:this.a=0;"
or something like.... = þ
but the "%" works fine = ) I tested it online many times..
^_^

Last edited by amonrabr; 03-22-2002 at 01:13 AM..
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 11:28 PM.


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