Skip to content

Commit 100b897

Browse files
authored
Fix gr.drawOffscreenIndicator (scp-fs2open#7295)
The scripted `gr.drawOffscreenIndicator` was missing a critical `resetClip();` which meant it was using whatever the previous stack's clipping distance was, and thus not draw in the actual correct location. This 1 line PR fixes that and the fix works as intended.
1 parent ba1f11f commit 100b897

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

code/scripting/api/libs/graphics.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,7 @@ ADE_FUNC(drawOffscreenIndicator, l_Graphics, "object Object, [boolean draw=true,
13191319
int dir;
13201320
float tri_separation;
13211321

1322+
offscreengauge->resetClip();
13221323
offscreengauge->calculatePosition(&target_point, &targetp->pos, &outpoint, &dir, &tri_separation);
13231324

13241325
if (draw) {

0 commit comments

Comments
 (0)