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-21-2002, 07:10 AM
thrashsoul thrashsoul is offline
Unregistered User
Join Date: Jan 2002
Posts: 595
thrashsoul is on a distinguished road
Send a message via AIM to thrashsoul
Question Script?

What is the Script for the light going in circles
Reply With Quote
  #2  
Old 03-21-2002, 07:12 AM
lordhelmut lordhelmut is offline
Registered User
lordhelmut's Avatar
Join Date: Aug 2001
Posts: 710
lordhelmut is on a distinguished road
Send a message via ICQ to lordhelmut Send a message via AIM to lordhelmut Send a message via Yahoo to lordhelmut
this is the levels forum
__________________

Check out the development at:
http://razza.org/lordhelmut/FantasyTales/index
Reply With Quote
  #3  
Old 03-21-2002, 07:51 AM
SSJVegeta1 SSJVegeta1 is offline
Banned
Join Date: Jan 2002
Location: Virginia Unites States
Posts: 248
SSJVegeta1 is on a distinguished road
Send a message via ICQ to SSJVegeta1 Send a message via AIM to SSJVegeta1 Send a message via Yahoo to SSJVegeta1
If your not talented enough to create that, than whatever project your working on is not gonna happen.
Reply With Quote
  #4  
Old 03-21-2002, 09:05 AM
SaijinGohan SaijinGohan is offline
Registered User
SaijinGohan's Avatar
Join Date: Jul 2001
Location: U.S.A - Ohio
Posts: 536
SaijinGohan is on a distinguished road
Send a message via AIM to SaijinGohan Send a message via MSN to SaijinGohan
Quote:
If your not talented enough to create that, than whatever project your working on is not gonna happen.
Very good point but you must admit it is a LIL hard.
__________________

Job: A Legend

And you think that you have played Graal forever? Ha!
Reply With Quote
  #5  
Old 03-21-2002, 09:31 AM
Jman9912-P2P Jman9912-P2P is offline
Registered User
Join Date: Nov 2001
Location: North Carolina!
Posts: 217
Jman9912-P2P is on a distinguished road
Send a message via AIM to Jman9912-P2P Send a message via Yahoo to Jman9912-P2P
well u would use cos and sin, its not that hard if u cant get it just reply again and ill help ya i want u to at least try u learn easier
__________________
AIM: Jman9912
Email: [email protected]
Reply With Quote
  #6  
Old 03-21-2002, 11:45 AM
amonrabr amonrabr is offline
Scripter
Join Date: Nov 2001
Location: Brazil
Posts: 374
amonrabr is on a distinguished road
Re: Script?

Quote:
Originally posted by thrashsoul
What is the Script for the light going in circles
Its very easy... but u need to know some maths..

1st) Sinus u will use for X
2nd) Cosinus u will use for y

timeout=.05;
this.a=(this.a+.1)%6.2;
showimg 1,light2.png,x+4*sin(this.a),y+4*cos(this.a);
changeimgcolor 1,1,1,1,0.8;

It should work...

Ps. Sinus of a number is something that will becoming big and so it slows...
3.14 is when it change the signal..

"%6.2" U dont need to use this, but so the "this.a" number never will stop.
This way it will back to "0" when "this.a" be equal 6.2(3.14*2 or 360o)

"4*" is the ray of the circle...

I understood now how they made that effects in the start ghost level on Graal2k2, its easy too...
Reply With Quote
  #7  
Old 03-21-2002, 09:45 PM
Falcor Falcor is offline
Darth Cucumber
Falcor's Avatar
Join Date: Mar 2001
Location: At School
Posts: 2,874
Falcor is on a distinguished road
Send a message via ICQ to Falcor Send a message via AIM to Falcor Send a message via MSN to Falcor Send a message via Yahoo to 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;
__________________

subliminal message: 1+1=3
Reply With Quote
  #8  
Old 03-22-2002, 12:52 AM
haunter haunter is offline
Registered User
haunter's Avatar
Join Date: Mar 2001
Posts: 7,989
haunter is on a distinguished road
Move this thread
Reply With Quote
  #9  
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
  #10  
Old 03-22-2002, 04:26 AM
thrashsoul thrashsoul is offline
Unregistered User
Join Date: Jan 2002
Posts: 595
thrashsoul is on a distinguished road
Send a message via AIM to thrashsoul
But what if you want it to go really fast
Reply With Quote
  #11  
Old 03-22-2002, 11:33 AM
joseyisleet joseyisleet is offline
Registered User
Join Date: Aug 2001
Posts: 378
joseyisleet is on a distinguished road
-=Josey=-
Look at the code, break it apart, then use your brain.
__________________
Account used by Josey and Howard.
Ali G: 'Is it cause i Black?'
Reply With Quote
  #12  
Old 03-23-2002, 02:02 AM
la_builder la_builder is offline
Registered User
Join Date: Jan 2002
Location: Holland
Posts: 154
la_builder is on a distinguished road
here and next time post in scripting

NPC Code:
if (playerenters) timeout=.05;
if (timeout) {
this.angle=(this.angle+.1)%6.28;
showimg 0.aball.gif,x+6*sin(this.angle),y+6*cos(this.angle );
timeout=.05;
}

__________________
Dark Frontier
The enemy is surrounding us all,more evil than a human could ever imagine.

Dark Fontier Coming Soon
Reply With Quote
  #13  
Old 03-24-2002, 02:59 AM
amonrabr amonrabr is offline
Scripter
Join Date: Nov 2001
Location: Brazil
Posts: 374
amonrabr is on a distinguished road
Quote:
Originally posted by thrashsoul
But what if you want it to go really fast
this.a=(this.a+.1)%6.2;

This ".1 " is the speed..


Quote:
here and next time post in scripting
if (playerenters) timeout=.05;
if (timeout) {
this.angle=(this.angle+.1)%6.28;
showimg 0.aball.gif,x+6*sin(this.angle),y+6*cos(this.angle );
timeout=.05;
}

timeout=.05;
if (timeout) {
this.angle=(this.angle+.1)%6.28;
showimg 0,aball.gif,x+6*sin(this.angle),y+6*cos(this.angle ); }
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:01 AM.


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