Skip to content

Commit 773cb18

Browse files
author
Roberto De Ioris
committed
fixed runtime builds
1 parent 25ab29b commit 773cb18

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

Source/UnrealEnginePython/Private/UObject/UEPyMaterial.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,14 @@ PyObject *py_ue_set_material(ue_PyUObject *self, PyObject * args)
5757
return PyErr_Format(PyExc_Exception, "argument is not a UMaterialInterface");
5858

5959
#if ENGINE_MINOR_VERSION >= 20
60+
#if WITH_EDITOR
6061
UStaticMesh *mesh = ue_py_check_type<UStaticMesh>(self);
6162
if (mesh)
6263
{
6364
mesh->SetMaterial(slot, material);
6465
Py_RETURN_NONE;
6566
}
67+
#endif
6668
#endif
6769

6870
UPrimitiveComponent *primitive = ue_py_check_type<UPrimitiveComponent>(self);

Source/UnrealEnginePython/Private/UObject/UEPyObject.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1857,12 +1857,8 @@ PyObject *py_ue_save_package(ue_PyUObject * self, PyObject * args)
18571857
u_object->SetFlags(RF_Public | RF_Standalone);
18581858
}
18591859
}
1860-
package = (UPackage *)StaticFindObject(nullptr, ANY_PACKAGE, UTF8_TO_TCHAR(name), true);
18611860
// create a new package if it does not exist
1862-
if (!package)
1863-
{
1864-
package = CreatePackage(nullptr, UTF8_TO_TCHAR(name));
1865-
}
1861+
package = CreatePackage(nullptr, UTF8_TO_TCHAR(name));
18661862
if (!package)
18671863
return PyErr_Format(PyExc_Exception, "unable to create package");
18681864

Source/UnrealEnginePython/Private/UObject/UEPySequencer.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ static bool magic_get_frame_number(UMovieScene *MovieScene, PyObject *py_obj, FF
6767

6868
}
6969

70+
#if WITH_EDITOR
7071
static void ImportTransformChannel(const FInterpCurveFloat& Source, FMovieSceneFloatChannel* Dest, FFrameRate DestFrameRate, bool bNegateTangents)
7172
{
7273
TMovieSceneChannelData<FMovieSceneFloatValue> ChannelData = Dest->GetData();
@@ -145,6 +146,7 @@ static bool ImportFBXTransform(FString NodeName, UMovieScene3DTransformSection*
145146

146147
return true;
147148
}
149+
#endif
148150

149151
#endif
150152

0 commit comments

Comments
 (0)