nano-laser

nano-laser

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Post Reply
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

nano-laser

Post by smoth »

A while back AF wrote a patch that allowed mods to change their nanolathe effect to a laser.

Could it be considered for the next version of spring?
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

I attempted it but gave up due to time and the more pressing matter of fixing an NTai bug

However it should be that nanospray should be bound to an explosion generater, using the direction of the nanospray/beam it would usually take as the direction vector of the explosion.
User avatar
Argh
Posts: 10920
Joined: 21 Feb 2005, 03:38

Post by Argh »

For that matter, I'd like to vote that all FX called from within Spring refer back to customExplosionGenerators. That would be very nice, and not terribly hard to do, codewise.
User avatar
1v0ry_k1ng
Posts: 4656
Joined: 10 Mar 2006, 10:24

Post by 1v0ry_k1ng »

supcom has laser nano beams
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Post by smoth »

I am not worried about supcom, I want nano-beams because they will be better then the particles we have now. Right now those particles are... a bit on the laggy side.
User avatar
clericvash
Posts: 1394
Joined: 05 Oct 2004, 01:05

Post by clericvash »

Yor right smoth, imagine all your conbots spamming out loads of it, that is what probably makes a lot of games lag...
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Post by Kloot »

e: obsolete
Last edited by Kloot on 09 Dec 2007, 19:59, edited 5 times in total.
User avatar
clericvash
Posts: 1394
Joined: 05 Oct 2004, 01:05

Post by clericvash »

Who cares what type of lag it makes, its still lag.
Kloot
Spring Developer
Posts: 1867
Joined: 08 Oct 2006, 16:58

Post by Kloot »

Because the fact that they are synced means the maxParticles setting does not affect them, nor would any replacement particle effect be (so it'd have to emit almost none to produce a noticeable improvement).
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Post by KDR_11k »

Set shownanoparticles to 0, aim the laser part during StartBuilding and fire the laser with emit-sfx in QueryNanoParticle? Hm, okay, that probably won't get called if shownanoparticles is 0 so you have to use a continuous effect that doesn't reflect if you actually have the ressources for building.
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Post by rattle »

Not gonna work because emit-sfx and beamlaser weapons (I assume this is what smoth wants) are no good.
Dunno if spring still crashes when the laser weapon wasn't aimed before the first shot but it will target the very same last target location instead of firing straight ahead in the direction of the piece rotation. Also the beamtime is (or was) limited to 0.0666 which is rather short...
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Post by KDR_11k »

I've been using force-fired laser beams in Dozerz quite successfully. Sure you should only have your beam live for one or two frames but you can emit it every frame without trouble.
User avatar
Fanger
Expand & Exterminate Developer
Posts: 1509
Joined: 22 Nov 2005, 22:58

Post by Fanger »

hackish work arounds FAIL HARD!!!!!!
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Post by rattle »

Does that mean they (beamlasers!) now use piece rotation?
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Post by KDR_11k »

Yep. Absolutely certain of that (worked since 74b1 or even earlier I think, I do know it worked fine already when I got the idea to make the dozers have sweeping beams). Try setting a dozer to on and firing at the landscape. A quick test suggests it works even if the weapon has never received an AimWeapon call.

BTW I'd have used one-frame lasers even if I could have them last longer because a beam cannot rotate after it has been fired so I have to fire a new beam when I want to rotate it anyway
User avatar
smoth
Posts: 22309
Joined: 13 Jan 2005, 00:46

Post by smoth »

Fanger wrote:hackish work arounds FAIL HARD!!!!!!
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Post by KDR_11k »

This workaround lets you use more effects than just lasers.
User avatar
jackalope
Posts: 695
Joined: 18 Jun 2006, 22:43

Post by jackalope »

smoth wrote:
Fanger wrote:hackish work arounds FAIL HARD!!!!!!
User avatar
KDR_11k
Game Developer
Posts: 8293
Joined: 25 Jun 2006, 08:44

Post by KDR_11k »

Build flamer > YUO!
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Synced particles not obeying maxparticles is imo a bug, and a rather big one imo.
Post Reply

Return to “Engine”