66 if (RopePoints.Count > 0) or (Gear^.Elasticity.QWordValue > 0) then |
66 if (RopePoints.Count > 0) or (Gear^.Elasticity.QWordValue > 0) then |
67 begin |
67 begin |
68 EnableTexture(false); |
68 EnableTexture(false); |
69 //glEnable(GL_LINE_SMOOTH); |
69 //glEnable(GL_LINE_SMOOTH); |
70 |
70 |
71 Tint($70, $70, $70, $FF); |
71 |
|
72 Tint(Gear^.Tint shr 24 div 3, Gear^.Tint shr 16 and $FF div 3, Gear^.Tint shr 8 and $FF div 3, Gear^.Tint and $FF); |
72 |
73 |
73 n:= RopePoints.Count + 2; |
74 n:= RopePoints.Count + 2; |
74 |
75 |
75 SetVertexPointer(@RopePoints.rounded[0], n); |
76 SetVertexPointer(@RopePoints.rounded[0], n); |
76 |
77 |
77 openglPushMatrix(); |
78 openglPushMatrix(); |
78 openglTranslatef(WorldDx, WorldDy, 0); |
79 openglTranslatef(WorldDx, WorldDy, 0); |
79 |
80 |
80 glLineWidth(3.0 * cScaleFactor); |
81 glLineWidth(3.0 * cScaleFactor); |
81 glDrawArrays(GL_LINE_STRIP, 0, n); |
82 glDrawArrays(GL_LINE_STRIP, 0, n); |
82 Tint($D8, $D8, $D8, $FF); |
83 Tint(Gear^.Tint); |
83 glLineWidth(2.0 * cScaleFactor); |
84 glLineWidth(2.0 * cScaleFactor); |
84 glDrawArrays(GL_LINE_STRIP, 0, n); |
85 glDrawArrays(GL_LINE_STRIP, 0, n); |
85 |
86 |
86 untint; |
87 untint; |
87 |
88 |
167 |
168 |
168 procedure DrawRope(Gear: PGear); |
169 procedure DrawRope(Gear: PGear); |
169 var roplen, i: LongInt; |
170 var roplen, i: LongInt; |
170 begin |
171 begin |
171 if Gear^.Hedgehog^.Gear = nil then exit; |
172 if Gear^.Hedgehog^.Gear = nil then exit; |
172 if (cReducedQuality and rqSimpleRope) <> 0 then |
173 if (Gear^.Tag = 1) or ((cReducedQuality and rqSimpleRope) <> 0) then |
173 DrawRopeLinesRQ(Gear) |
174 DrawRopeLinesRQ(Gear) |
174 else |
175 else |
175 begin |
176 begin |
176 roplen:= 0; |
177 roplen:= 0; |
177 if RopePoints.Count > 0 then |
178 if RopePoints.Count > 0 then |