View Issue Details

IDProjectCategoryView StatusLast Update
0005822Multi Theft Auto : San AndreasClientpublic2015-06-23 00:10
ReporterGhOsT[X]Assigned Toccw 
PrioritynormalSeverityfeatureReproducibilityN/A
Status resolvedResolutionfixed 
Product Version 
Target Version1.5Fixed in Version1.5 
Summary0005822: [Request] Light creation
Description

I'm Requesting a function to create gta lights.

See additional info.

Additional Information

The names of the function,could be: createLight, createFlash,
createFlashLight, createFlashLightAt.

And the parameters: x,y,z,color,radius

The opcodes are: createLight (09E5) - createFlash (058A).

On GTA Forums, there are some more info.

void add_gta_light(char type, float pos_x_in, float pos_y_in, float pos_z_in, float dir_x_in, float dir_y_in, float dir_z_in, float radius_in, float red_in, float green_in, float blue_in, char a12, char a13, float alpha_in)

address: 0x007000E0

Source: http://www.gtaforums.com/index.php?showtopic=194199&view=findpost&p=1060278603

TagsNo tags attached.

Relationships

has duplicate 0006024 closed New issues [Request] createLight( float x, float y, float z, float size, int r, int g, int b, int a, visibleTo ) 
related to 0007582 closed New issues Add Searchlight Function 
child of 0003344 closed New Feature Requests Requested features tracker 
child of 0008737 resolvedccw Source patches PointLight Creation 

Activities

Talidan

2011-01-20 08:46

administrator   ~~0012640

what's the difference between a flash light and a Corona?

AcidbRain

2011-01-20 11:17

viewer   ~~0012642

"...this will only create the part of the light that actually illuminates objects."

GhOsT[X]

2011-01-20 22:21

viewer   ~~0012649

Last edited: 2011-01-20 23:29

Hm. one of the differences are clearly in the function, corona doesn't has a direction parameter, and light does. ('Atleast' is documented with the 3 direction parameters in GTA Forums.)

Another thing is that lights have two types: point and spot.

But needs to check how it affects the game, if causes any problems to the graphic and if the memory address is correct.

This can be low priority, but its a amazing feature that mta needs.

I just have this screenshot as example: http://img641.imageshack.us/img641/7465/samp380g.png (Flashlight created by SCM, using the 095C opcode). (The red effect).

Kernell

2011-06-12 12:48

reporter   ~~0013657

Please add a feature.

benox583

2011-06-16 06:02

viewer   ~~0013686

You can do this if you add a 2D FX in the DFF, but with script you can do more things of course, but its possible , I made maps with this : http://www.youtube.com/watch?v=hVJtMPh8SJI

bug_Spanish4Life

2011-11-26 12:47

viewer   ~~0015280

*bump
This gonna be added? :)

Strit

2012-02-29 13:15

viewer   ~~0016180

Please add.

el_motoblock

2012-03-01 10:12

viewer   ~~0016185

yes, its very important

benox583

2012-03-04 00:38

viewer   ~~0016224

Yo , Lets talk ! Dudes ! This is already possible in DFF and there is no huge difference between a gta light and a corona marker -.-

The big difference is the gta light have a light effect on vehicles and peds and some small objects, but this light effect is really poorly made, I find it only good on vehicles, I tested it !

  • corona marker can be scripted to flash or other animation, gta light have limited animation.

So I think the best is to look if this http://en.wikipedia.org/wiki/Per-pixel_lighting Per-pixel lighting or other good lighting is possible using shaders Element.

Dragon

2012-03-04 02:34

reporter   ~~0016225

the question is not whether its poorly made or not. the question is why would you want to deny people access to this, if its a feature of gta.

LeetWoovie

2012-03-04 02:40

viewer   ~~0016226

If someone gets a .patch file for MTA, then perhaps they'll look into it. Why should the devs bother wasting time adding this themselves ?

Kenix

2012-03-05 15:24

updater   ~~0016239

Please add a feature.

LooooP

2012-03-05 16:38

reporter   ~~0016240

LeetWoovie: [...] Why should the devs bother wasting time adding this themselves ?

Adding new functions aren't waste of time

WolfPire

2012-03-27 18:10

viewer   ~~0016380

Last edited: 2012-03-27 18:10

These functions are quite esscencial for MTA:SA.

Cleo3 can perfectly handle these functions, so why LUA cannot?

We should totally add these functions to the library and make it an MTA Element.

This could be really helpful in the creating of many good resources. In my opinion i've been waiting for a function like this to appear. It is indeed a good idea to add them.

Coronas aren't light elements, they are objects which only have a flashing effect on itself, and it doesn't produce any reflection effect on any object nor world.

http://imageshack.us/photo/my-images/194/testrzn.jpg

LeetWoovie

2012-03-29 17:44

viewer   ~~0016394

Adding new functions when you have a ton of bugs is. My point is, if you want this perhaps you should learn C++ and create your .patch for the team.

TopAz

2012-04-01 15:31

viewer   ~~0016406

Agree with the feature. It's needed.

benox583

2012-04-04 05:45

viewer   ~~0016418

+1 LeetWoovie

You can also do this http://www.youtube.com/watch?v=1a6_GzKegRM

x86

2012-04-10 11:14

administrator   ~~0016448

devs:

Use RpWorldAddLight ( ... ) ---\/

struct RpLight
{
RwObjectFrame object;
float radius;
RwColorFloat color;
float unknown1;
RwList sectors;
RwListEntry globalLights;
unsigned short frame;
unsigned short unknown2;
};

MrMuLTiVaN

2012-04-24 14:38

viewer   ~~0016530

This is the neon light from SA-MP,

http://www.abload.de/img/mta-screen_2012-04-22bejlo.png

I think you can do this with material colours and the .dff file, but I don't know how, I can't do it.

Ghost_X

2012-07-07 15:14

viewer   ~~0016983

LeetWoovie, that's why i suggested to put this as a low priority change.

DivX

2013-11-01 14:36

reporter   ~~0019589

Last edited: 2013-11-01 14:37

View 2 revisions

bump*
is it alive?

Lex128

2014-04-26 12:01

reporter   ~~0020768

Patch for light elements http://puu.sh/8o0f6.patch

qaisjp

2014-04-26 12:19

administrator   ~~0020769

Isn't this already in MTA:Eir?

ixjf

2014-04-26 12:23

viewer   ~~0020770

Last edited: 2014-04-26 12:24

View 2 revisions

Dynamic lighting already exists in MTA:Eir, indeed. I don't know exactly what types of light sources there are, though.

Lex128

2014-04-26 15:58

reporter   ~~0020771

Dynamic lighting exists in MTA now too, but there is not functions for using it

Issue History

Date Modified Username Field Change