Revision: 1522
http://rigsofrods.svn.sourceforge.net/rigsofrods/?rev=1522&view=rev
Author: rorthomas
Date: 2010-08-19 18:29:09 +0000 (Thu, 19 Aug 2010)
Log Message:
-----------
closes Bug #374
Modified Paths:
--------------
trunk/source/main/Beam.cpp
trunk/source/main/Beam.h
Modified: trunk/source/main/Beam.cpp
===================================================================
--- trunk/source/main/Beam.cpp 2010-08-19 12:26:43 UTC (rev 1521)
+++ trunk/source/main/Beam.cpp 2010-08-19 18:29:09 UTC (rev 1522)
@@ -486,6 +486,7 @@
totalmass=0;
parkingbrake=0;
lights=1;
+ reverselight=false;
free_node=0;
free_beam=0;
free_contacter=0;
@@ -8757,7 +8758,8 @@
it->lockTruck->blinkingtype =
blinkingtype;
//for(int k=0;k<4;k++)
// lockTruck->setCustomLight(k,
getCustomLight(k));
-
+ //forward reverse light e.g. for
trailers
+
it->lockTruck->reverselight=getReverseLightVisible();
}
}
}
@@ -9771,7 +9773,7 @@
} else if(flares[i].type == 'b') {
isvisible = getBrakeLightVisible();
} else if(flares[i].type == 'R') {
- if(engine)
+ if(engine || reverselight)
isvisible = getReverseLightVisible();
else
isvisible=false;
@@ -11140,8 +11142,10 @@
{
if(state==NETWORKED)
return netReverseLight;
- if (!engine) return 0;
- return (engine->getGear() < 0);
+ if (!engine && !reverselight) return 0;
+ if (engine) return (engine->getGear() < 0);
+ if (reverselight) return true;
+ return false;
}
// Utility functions
///////////////////////////////////////////////////////////
Modified: trunk/source/main/Beam.h
===================================================================
--- trunk/source/main/Beam.h 2010-08-19 12:26:43 UTC (rev 1521)
+++ trunk/source/main/Beam.h 2010-08-19 18:29:09 UTC (rev 1522)
@@ -330,6 +330,7 @@
bool rescuer;
int parkingbrake;
int lights;
+ bool reverselight;
int smokeId;
int editorId;
bool shadowOptimizations;
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
This SF.net email is sponsored by
Make an app they can't live without
Enter the BlackBerry Developer Challenge
http://p.sf.net/sfu/RIM-dev2dev
_______________________________________________
Rigsofrods-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rigsofrods-devel