Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / how do i create a light

Author
Message
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 8th Jan 2004 14:17
i want to create a light like the sun light that is flashing...
or like a light that come from a lamp that you cant look at him...
thankssssss
Turoid
21
Years of Service
User Offline
Joined: 1st Nov 2003
Location: The Netherlands
Posted: 8th Jan 2004 15:12
first make the light:

make light lightnumber

to position the light:

position light lightnumber,x,y,z

note that you can only make 8 lights. and see for more ´light information´ in darkbasic help.

cheers

if I = 1 then I = 1 else I = 0
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 8th Jan 2004 22:59
i didnt mean to an simple light...i means to lisgh like sun light or something like that...
thanks anyway!!!
Mattman
21
Years of Service
User Offline
Joined: 5th Jun 2003
Location: East Lansing
Posted: 8th Jan 2004 23:56
http://www.thegamecreators.com/?gf=newsletter_issue_6#Article5 here ya go

I am mischeivious
RoooooOoooooKoooooKoooooRoooooOoooooKoooooKooooo!
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 9th Jan 2004 14:13 Edited at: 9th Jan 2004 14:14
the code doesnt work in darkbasic....it work only at dbpro...
somebody can ve me the codr for darkbasic?
thasnkssssssss
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 10th Jan 2004 17:30
somebody?
John H
Retired Moderator
22
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 10th Jan 2004 17:45
Do you want global illumination, or just an object to look like a sun?


We need help! Email us! [email protected]
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 10th Jan 2004 20:08
i want to do with this a sun and more things...
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 15th Jan 2004 00:15
nobody knows?
Don Malone
22
Years of Service
User Offline
Joined: 27th Apr 2003
Location: Birmingham, Alabama
Posted: 15th Jan 2004 03:02
To make it work in DarkBasic Classic (I'm using 1.13) you have to change line 2

Here is the working code



Still unsure if this effect is what you are after but here it is.

Quote: "SET OBJECT Object Number, Wireframe, Transparency, Cull, Filter"


Quote: "SET OBJECT
This command sets the internal properties of a specified 3D object number. You must specify a 3D Object Number between 1 and 65535. When the wireframe flag is set to 0, the object only shows it's wireframe form. When the transparency flag is set to 0, all parts of the object colored black are not drawn to the screen. When the cull flag is set to 0, the object will draw polygons normally hidden due to the direction the polygon faces. The Filter Flag activates and deactivates texture filtering, which controls the smoothing effect of the texture as it is mapped to the object. The Light Flag activates and deactivates the objects sensitivity to any lights in the scene. The Fog Flag activates and deactivates the objects sensitivity to fog in the scene. The Ambient Flag activates and deactivates the objects sensitivity to ambient light in the scene. The object number and flag values should be specified using integer values."


I only used the first four flags of the seven and only because DB forced me to use them.

The quotes are from the Help File; version 1.13 revision.


Wasting CPU Cycles since the 286 was a hot machine.
Shafan
21
Years of Service
User Offline
Joined: 22nd Dec 2003
Location: israel
Posted: 15th Jan 2004 16:11
thankssssssssssssssssssssssssssssssssssssssss
Don Malone
22
Years of Service
User Offline
Joined: 27th Apr 2003
Location: Birmingham, Alabama
Posted: 16th Jan 2004 01:21
Hey Shafan

You seem to have a air leak there. Might want to get that checked

<JK>

Wasting CPU Cycles since the 286 was a hot machine.

Login to post a reply

Server time is: 2025-05-22 08:58:07
Your offset time is: 2025-05-22 08:58:07