Revision: 1695
          http://rigsofrods.svn.sourceforge.net/rigsofrods/?rev=1695&view=rev
Author:   rorthomas
Date:     2011-02-22 21:48:03 +0000 (Tue, 22 Feb 2011)

Log Message:
-----------
fixes #378

Modified Paths:
--------------
    trunk/source/main/physics/input_output/BeamLoadTruck.cpp

Modified: trunk/source/main/physics/input_output/BeamLoadTruck.cpp
===================================================================
--- trunk/source/main/physics/input_output/BeamLoadTruck.cpp    2011-02-22 
21:29:39 UTC (rev 1694)
+++ trunk/source/main/physics/input_output/BeamLoadTruck.cpp    2011-02-22 
21:48:03 UTC (rev 1695)
@@ -1993,7 +1993,8 @@
                {
                        //parse ropes
                        int id1=0, id2=0, key=0, group=0;
-                       int result = sscanf(line,"%i, %i, %i, %i", &id1, &id2, 
&key, &group);
+                       char option = 'n';
+                       int result = sscanf(line,"%i, %i, %i, %i, %c", &id1, 
&id2, &key, &option);
                        if (result < 2 || result == EOF) {
                                LogManager::getSingleton().logMessage("Error 
parsing File (Ropes) " + String(fname) +" line " + 
StringConverter::toString(linecounter) + ". trying to continue ...");
                                continue;
@@ -2011,7 +2012,9 @@
                                LogManager::getSingleton().logMessage("cannot 
create rope: beams limit reached ("+StringConverter::toString(MAX_BEAMS)+"): " 
+ String(fname) +" line " + StringConverter::toString(linecounter) + ". trying 
to continue ...");
                                continue;
                        }
-                       int pos=add_beam(&nodes[id1], &nodes[id2], manager, 
parent, BEAM_NORMAL, default_break * default_break_scale, default_spring * 
default_spring_scale, default_damp * default_damp_scale, detacher_group_state);
+                       int htype = BEAM_NORMAL;
+                       if (option=='i') htype = BEAM_INVISIBLE;
+                       int pos=add_beam(&nodes[id1], &nodes[id2], manager, 
parent, htype, default_break * default_break_scale, default_spring * 
default_spring_scale, default_damp * default_damp_scale, detacher_group_state);
                        beams[pos].bounded=ROPE;
 
                        rope_t r;


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in 
Real-Time with Splunk. Collect, index and harness all the fast moving IT data 
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business 
insights. http://p.sf.net/sfu/splunk-dev2dev 
_______________________________________________
Rigsofrods-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/rigsofrods-devel

Reply via email to