Fix projectile lights for '98

Fix projectile lights for '98

Discuss Lua based Spring scripts (LuaUI widgets, mission scripts, gaia scripts, mod-rules scripts, scripted keybindings, etc...)

Moderator: Moderators

Post Reply
User avatar
Jools
XTA Developer
Posts: 2816
Joined: 23 Feb 2009, 16:29

Fix projectile lights for '98

Post by Jools »

I've noticed that projectile lights causes lua memory error in spring 98, and it also possibly interferes with lups. As I've not had anything to do with this widget, I ask if maybe someone else has already figured out what it does wrong.

For example, it seems like using display lists makes it slower, how can that be?

Here is the xta one (I understand the unit specific parts needs to be customised per game):

https://code.google.com/p/xta-springrts ... lights.lua
User avatar
Silentwings
Posts: 3720
Joined: 25 Oct 2008, 00:23

Re: Fix projectile lights for '98

Post by Silentwings »

Afaik the BA version has none of these issues: http://imolarpg.dyndns.org/trac/balates ... lights.lua - I don't know how portable it is.
For example, it seems like using display lists makes it slower, how can that be?
Except for issues caused by poor gfx drivers, I think this can happen only if the display list is called so few times before it is remade that the overhead for its creation outweighs the time saved by calling it as a list. There are also some gfx cards where, by design, gllists make essentially no difference. But I am not at all expert here, this is just observations from having written alot of widgets/gadgets.
User avatar
Jools
XTA Developer
Posts: 2816
Joined: 23 Feb 2009, 16:29

Re: Fix projectile lights for '98

Post by Jools »

Ahaa, that explains some of my observations. For my GPU, lists have not made a big difference, things with lists are often more expensive than without them. I have Geforce 460.

I also thought that the less frequently you call a list, the better. So I'm not an expert either.
Post Reply

Return to “Lua Scripts”