diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 9c2326399fb0b3710e15c6e13d06f93cbd282caa..819b9cc352b9b9ecfeb2cb8868768259d4dc054c 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -148,6 +148,7 @@ set(SRB2_CORE_RENDER_SOURCES
 	r_things.h
 	r_textures.h
 	r_patch.h
+	r_patchrotation.h
 	r_picformats.h
 	r_portal.h
 )
diff --git a/src/r_patch.h b/src/r_patch.h
index 71f185c9d8cb956e9917f36d3eab260fa259f974..6991d3637733ce70b68ed9c97b8ad45859f1f2bf 100644
--- a/src/r_patch.h
+++ b/src/r_patch.h
@@ -31,8 +31,6 @@ void *Patch_CreateGL(patch_t *patch);
 void Patch_Rotate(patch_t *patch, INT32 angle, INT32 xpivot, INT32 ypivot, boolean flip);
 patch_t *Patch_GetRotated(patch_t *patch, INT32 angle, boolean flip);
 patch_t *Patch_GetRotatedSprite(spriteframe_t *sprite, size_t frame, size_t spriteangle, boolean flip, void *info, INT32 rotationangle);INT32 R_GetRollAngle(angle_t rollangle);
-extern fixed_t rollcosang[ROTANGLES];
-extern fixed_t rollsinang[ROTANGLES];
 #endif
 
 #endif // __R_PATCH__
diff --git a/src/r_patchrotation.c b/src/r_patchrotation.c
index 77544c3ac265dce17adc886ef7924916d1a32c3c..83eb4eeba0e2af34f76f18fb5a7d964e513b7d1d 100644
--- a/src/r_patchrotation.c
+++ b/src/r_patchrotation.c
@@ -1,6 +1,6 @@
 // SONIC ROBO BLAST 2
 //-----------------------------------------------------------------------------
-// Copyright (C) 2018-2020 by Jaime "Lactozilla" Passos.
+// Copyright (C) 2020 by Jaime "Lactozilla" Passos.
 //
 // This program is free software distributed under the
 // terms of the GNU General Public License, version 2.
@@ -9,17 +9,12 @@
 /// \file  r_patchrotation.c
 /// \brief Patch rotation.
 
-#include "r_patch.h"
-#include "r_picformats.h"
+#include "r_patchrotation.h"
 #include "r_things.h" // FEETADJUST
 #include "z_zone.h"
 #include "w_wad.h"
 
 #ifdef ROTSPRITE
-
-static rotsprite_t *RotatedPatch_Create(INT32 numangles);
-static void RotatedPatch_DoRotation(rotsprite_t *rotsprite, patch_t *patch, INT32 angle, INT32 xpivot, INT32 ypivot, boolean flip);
-
 fixed_t rollcosang[ROTANGLES];
 fixed_t rollsinang[ROTANGLES];
 
diff --git a/src/r_patchrotation.h b/src/r_patchrotation.h
new file mode 100644
index 0000000000000000000000000000000000000000..2744f71d25380469b30b1fdcf8b5112578a2abd8
--- /dev/null
+++ b/src/r_patchrotation.h
@@ -0,0 +1,21 @@
+// SONIC ROBO BLAST 2
+//-----------------------------------------------------------------------------
+// Copyright (C) 2020 by Jaime "Lactozilla" Passos.
+//
+// This program is free software distributed under the
+// terms of the GNU General Public License, version 2.
+// See the 'LICENSE' file for more details.
+//-----------------------------------------------------------------------------
+/// \file  r_patchrotation.h
+/// \brief Patch rotation.
+
+#include "r_patch.h"
+#include "r_picformats.h"
+
+#ifdef ROTSPRITE
+rotsprite_t *RotatedPatch_Create(INT32 numangles);
+void RotatedPatch_DoRotation(rotsprite_t *rotsprite, patch_t *patch, INT32 angle, INT32 xpivot, INT32 ypivot, boolean flip);
+
+extern fixed_t rollcosang[ROTANGLES];
+extern fixed_t rollsinang[ROTANGLES];
+#endif
diff --git a/src/r_things.c b/src/r_things.c
index b7d7302f8283f032e68ca801cdc2b098db2d512d..33b9820c81d18a53f8605935f293eda2ee5ac026 100644
--- a/src/r_things.c
+++ b/src/r_things.c
@@ -25,6 +25,7 @@
 #include "i_system.h"
 #include "r_things.h"
 #include "r_patch.h"
+#include "r_patchrotation.h"
 #include "r_picformats.h"
 #include "r_plane.h"
 #include "r_portal.h"