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 01-14-2002, 07:33 AM
MeoDea MeoDea is offline
Registered User
Join Date: Jan 2002
Location: Canada
Posts: 10
MeoDea is on a distinguished road
Send a message via AIM to MeoDea
Need a few examples here

I need some code examples, to try and learn from.

First, i need something that uses sin cos and tan, or whichever are needed to make something, say,and image, circle the player

Second, i need an example of how one would use arrays to keep track of many many things at once

Any help would be GREATLY appreciated
__________________
----
Mook?
Reply With Quote
  #2  
Old 01-14-2002, 07:45 AM
Faheria_LAT1 Faheria_LAT1 is offline
Seraphim Warrior
Faheria_LAT1's Avatar
Join Date: Oct 2001
Location: QUÉBEC!!!!!!1
Posts: 2,040
Faheria_LAT1 is on a distinguished road
Send a message via ICQ to Faheria_LAT1 Send a message via AIM to Faheria_LAT1
Re: Need a few examples here

Quote:
Originally posted by MeoDea
I need some code examples, to try and learn from.

First, i need something that uses sin cos and tan, or whichever are needed to make something, say,and image, circle the player

Second, i need an example of how one would use arrays to keep track of many many things at once

Any help would be GREATLY appreciated

I think tan cant be used.. here's something VERY cool made by Warren, an ex-Graalian He also made the Popular Gravity script in the first pages (unless someone revived it) of the forum.

PHP Code:
//Eye made by Warren
if (playertouchsmetoweapons Eye of Protection;
if (
weaponfired&&playermp>=15) {
 
playermp-=15;
 
this.blah=0;
 
freezeplayer 0.75;
 while (
this.blah<6.3) {
  
putexplosion 1,cos(this.blah)*12+playerx,sin(this.blah)*6+playery;
  
putexplosion2 3,1,cos(this.blah)*4+playerx,sin(this.blah)*6+playery;
  
this.blah+=0.1;
 }

__________________


"I like movies where the guy shoots stuff, and then it blows up, and then this other guy shoots him, and then the first guy drives through a Coke sign, and it blows up, and the car flips over in slow motion, and then the guy gets out and pops his arm back in place, and then they fight 'cause they're out of bullets, and the guy says something like "This is Walmart, boy...and you just got price-checked!" - Broken Saints

"There is no greater sorrow than to recall in misery when we were happy" - Dante

"If you know yourself but not the enemy, for every victory gained you will also suffer a defeat" - Sun Tzu, The Art Of War

"Kingdoms ...rising without word. Collapsing without warning." - Broken Saints

Account now used by Silver and Mmmmkay
yoshee15 account has run out :[[[
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 08:54 PM.


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