Graal Forums  

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

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 11-15-2005, 09:50 AM
Raeiphon Raeiphon is offline
I never asked for this.
Join Date: Jun 2005
Posts: 855
Raeiphon is on a distinguished road
Light/Cloud Effects?

Say I wanted to use a NPC which has an image of mist or whatnot, and actually transpose that mist into a light form? How would I go about doing that?

setcoloreffect?
drawaslight?
__________________

I hope for nothing. I fear nothing. I am free.
Reply With Quote
  #2  
Old 11-15-2005, 10:05 AM
Lance Lance is offline
dark overlord
Lance's Avatar
Join Date: Sep 2003
Location: Space Jam Mountain
Posts: 5,072
Lance is on a distinguished road
Quote:
Originally Posted by Raeiphon
Say I wanted to use a NPC which has an image of mist or whatnot, and actually transpose that mist into a light form? How would I go about doing that?

setcoloreffect?
drawaslight?
You could add a default light NPC and then change its image.
Reply With Quote
  #3  
Old 11-22-2005, 11:13 AM
Raeiphon Raeiphon is offline
I never asked for this.
Join Date: Jun 2005
Posts: 855
Raeiphon is on a distinguished road
It appears the same as the image =/
__________________

I hope for nothing. I fear nothing. I am free.
Reply With Quote
  #4  
Old 11-23-2005, 12:57 AM
Janus Janus is offline
Submit to my will
Janus's Avatar
Join Date: Dec 2004
Location: No stalking the Odin.
Posts: 16
Janus is on a distinguished road
Send a message via AIM to Janus
Quote:
Originally Posted by Raeiphon
It appears the same as the image =/
Isn't that the point? o_O

K, I'm not sure how much you know, or what the problem is, so I'm just gonna bust through all the possible problems I can think of.

The default light npc:
NPC Code:
// NPC made by Stefan Knorr
if (created) {
setimg light2.png; // change light2.png to the mist image.
dontblock;
}
//#CLIENTSIDE
if (playerenters) {
setcoloreffect 1,1,1,0.99; // make sure the alpha is below 1 (red,green,blue,alpha)
drawaslight;
}



Make sure you have light effects enabled and all that good stuff.

If you're wanting the npc to SHOW the mist and not BE the mist itself, use showimg, changeimgcolors, and changeimgvis.
They are used:
NPC Code:
showimg index,filename,x,y; //make sure the index number matches for these
changeimgcolors index,red,green,blue,alpha; // values are 0-1, keep alpha below 1
changeimgvis index,layer; // have layer at 3



Also, don't forget to have //#CLIENTSIDE above that stuff.



Typing is fun.
__________________


Manager of Babylon
Join us.
We have cookies.
Reply With Quote
  #5  
Old 11-23-2005, 07:00 AM
protagonist protagonist is offline
Banned
protagonist's Avatar
Join Date: May 2003
Location: CAW
Posts: 5,586
protagonist is on a distinguished road
Send a message via AIM to protagonist Send a message via MSN to protagonist
You could use a combination of lights and then change the alpha of the mist.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 10:55 AM.


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