# Editor Scripting

**URL:** https://forums.unrealengine.com/c/development-discussion/pipeline-plugins/editor-scripting/45.md?page=63

[Latest](https://forums.unrealengine.com/latest.md) · [Categories](https://forums.unrealengine.com/categories.md) · [Tags](https://forums.unrealengine.com/tags.md)

**Page:** 64

---

## [Will UE5 have full support for scripting with python?](https://forums.unrealengine.com/t/will-ue5-have-full-support-for-scripting-with-python/449350)

<div class="topic-metadata">

**Author:** [@Albus70007](https://forums.unrealengine.com/u/Albus70007)\
**Replies:** 3\
**Last updated:** [May 23, 2019, 1:55am UTC](https://forums.unrealengine.com/t/will-ue5-have-full-support-for-scripting-with-python/449350 "2019-05-23T01:55:12Z")

</div>

Hello, i would like to know if unreal engine 5 (or sooner versions) will have full support for scripting un Python, i really love and want to use UE, but Python is indispensable for me, but if UE5 will have Python as a m…

---

## [Text array Plus Text Array?](https://forums.unrealengine.com/t/text-array-plus-text-array/449383)

<div class="topic-metadata">

**Author:** [@Dark\_Jubei](https://forums.unrealengine.com/u/Dark_Jubei)\
**Replies:** 4\
**Last updated:** [May 22, 2019, 12:55pm UTC](https://forums.unrealengine.com/t/text-array-plus-text-array/449383 "2019-05-22T12:55:04Z")

</div>

Hi All, I’m doing something very simple in unreal. Its a UMG random name generator with two arrays, one full of the first set of words, the other with the second. It works fine with two text boxes but i want to set the…

---

## [XML map with Python or Lua scripting](https://forums.unrealengine.com/t/xml-map-with-python-or-lua-scripting/449349)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_e10a6464](https://forums.unrealengine.com/u/anonymous_user_e10a6464)\
**Replies:** 0\
**Last updated:** [May 21, 2019, 10:07pm UTC](https://forums.unrealengine.com/t/xml-map-with-python-or-lua-scripting/449349 "2019-05-21T22:07:03Z")

</div>

I have a UE4 game that loads XML map files. I want the XML map files to support Python scripts that enable map-specific game logic. This is for a board game simulation of HeroQuest (Milton Bradley, Games Workshop) (198…

---

## [Relaoding a second time a python class subclassing unreal.Object crashes the editor?](https://forums.unrealengine.com/t/relaoding-a-second-time-a-python-class-subclassing-unreal-object-crashes-the-editor/126256)

<div class="topic-metadata">

**Author:** [@MightyJacky](https://forums.unrealengine.com/u/MightyJacky)\
**Replies:** 3\
**Last updated:** [May 21, 2019, 11:05am UTC](https://forums.unrealengine.com/t/relaoding-a-second-time-a-python-class-subclassing-unreal-object-crashes-the-editor/126256 "2019-05-21T11:05:47Z")

</div>

Hello! First time here, starting to work with Python scripting for the editor :slight\_smile: Sorry for the long post! I encountered a problem/crash in the way python classes inheriting unreal.Object are reloaded when re…

---

## [Custom panel/tools window in the editor via Python?](https://forums.unrealengine.com/t/custom-panel-tools-window-in-the-editor-via-python/124342)

<div class="topic-metadata">

**Author:** [@Eric.Pavey](https://forums.unrealengine.com/u/Eric.Pavey)\
**Replies:** 2\
**Last updated:** [May 17, 2019, 6:23pm UTC](https://forums.unrealengine.com/t/custom-panel-tools-window-in-the-editor-via-python/124342 "2019-05-17T18:23:40Z")

</div>

Anyone got any sort of custom panel / tools window up and running via Python in the editor? I’d like to start authoring tools for people and providing a nice UI, since having them import/run python code is super clunky. …

---

## [Can the editor's Python API access game code?](https://forums.unrealengine.com/t/can-the-editors-python-api-access-game-code/449112)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_bc29b170](https://forums.unrealengine.com/u/anonymous_user_bc29b170)\
**Replies:** 0\
**Last updated:** [May 17, 2019, 10:50am UTC](https://forums.unrealengine.com/t/can-the-editors-python-api-access-game-code/449112 "2019-05-17T10:50:46Z")

</div>

I have successfully been using Python to automate certain tasks in the Unreal Editor. However I am currently at a point where I need to reference a UStruct from my game’s code (in order to create a Data Table asset where…

---

## [pythonscriptCommandlet looked like a commandlet, but we could not find the class.](https://forums.unrealengine.com/t/pythonscriptcommandlet-looked-like-a-commandlet-but-we-could-not-find-the-class/124196)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_204af5b3](https://forums.unrealengine.com/u/anonymous_user_204af5b3)\
**Replies:** 1\
**Last updated:** [May 16, 2019, 9:33pm UTC](https://forums.unrealengine.com/t/pythonscriptcommandlet-looked-like-a-commandlet-but-we-could-not-find-the-class/124196 "2019-05-16T21:33:20Z")

</div>

I am Using Unreal 4.21 i use this method ,but get the error : C:\\Program Files\\Epic Games\\UE\_4.21\\Engine\\Binaries\\Win64\>UE4Editor-Cmd.exe -run=pythonscript -script=“C:\\workspace est.py” \[2019.03.29-14.50.40:571\] 0\]Lo…

---

## [I can't seem to unload my instanced sub-levels](https://forums.unrealengine.com/t/i-cant-seem-to-unload-my-instanced-sub-levels/395810)

<div class="topic-metadata">

**Author:** [@Googlepaard](https://forums.unrealengine.com/u/Googlepaard)\
**Replies:** 2\
**Last updated:** [May 16, 2019, 7:09am UTC](https://forums.unrealengine.com/t/i-cant-seem-to-unload-my-instanced-sub-levels/395810 "2019-05-16T07:09:12Z")

</div>

Hey guys, first time poster and Blueprint noob here. I’ve been trying to unload specific Sub-Level instances which I spawned, I’ve tried numerous things, but can’t seem to get it to work properly. I figure it got someth…

---

## [How to implement drag and drop for external assets in plugin window?](https://forums.unrealengine.com/t/how-to-implement-drag-and-drop-for-external-assets-in-plugin-window/126164)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_07ba773b](https://forums.unrealengine.com/u/anonymous_user_07ba773b)\
**Replies:** 0\
**Last updated:** [May 14, 2019, 7:21pm UTC](https://forums.unrealengine.com/t/how-to-implement-drag-and-drop-for-external-assets-in-plugin-window/126164 "2019-05-14T19:21:27Z")

</div>

I’m creating a plugin with an editor window, and I want to implement a way to drag and drop an FBX file from outside the Unreal Editor onto the editor window. The behaviour I’m trying to imitate is the way that you can …

---

## [Different behaviors of running scripts from Editor and Commandlet?](https://forums.unrealengine.com/t/different-behaviors-of-running-scripts-from-editor-and-commandlet/125326)

<div class="topic-metadata">

**Author:** [@kakyoism](https://forums.unrealengine.com/u/kakyoism)\
**Replies:** 6\
**Last updated:** [April 29, 2019, 10:28am UTC](https://forums.unrealengine.com/t/different-behaviors-of-running-scripts-from-editor-and-commandlet/125326 "2019-04-29T10:28:01Z")

</div>

Running the following script in the Editor, I see the target objects selected in the Content Browser. import unreal as ue toselect = '/Game/Path/To/My1', '/Game/Path/To/My2', \] ue.EditorAssetLi…

---

## [Multi-Slot Grid based Inventory System](https://forums.unrealengine.com/t/multi-slot-grid-based-inventory-system/448829)

<div class="topic-metadata">

**Author:** [@MetalKobra1](https://forums.unrealengine.com/u/MetalKobra1)\
**Replies:** 0\
**Last updated:** [May 12, 2019, 6:46am UTC](https://forums.unrealengine.com/t/multi-slot-grid-based-inventory-system/448829 "2019-05-12T06:46:09Z")

</div>

The concept is very similar to Champions of Norrath’s (Realms of Everquest or Return to Arms) inventory system. Where there is a grid and the items vary is size: 1x1; 2x1; 1x2 ect. I made a ui inventory window wi…

---

## [Must restart the Editor to use updated Python code?](https://forums.unrealengine.com/t/must-restart-the-editor-to-use-updated-python-code/125847)

<div class="topic-metadata">

**Author:** [@kakyoism](https://forums.unrealengine.com/u/kakyoism)\
**Replies:** 7\
**Last updated:** [May 10, 2019, 11:39am UTC](https://forums.unrealengine.com/t/must-restart-the-editor-to-use-updated-python-code/125847 "2019-05-10T11:39:00Z")

</div>

I’m using 4.21. I found that if my Python scripts changed in an external editor, the change is not always picked up by an open project in Unreal, even after deleting all the .pyc and caches. The only way to make sure i…

---

## [Python access to TSoftObjectPtr property fails](https://forums.unrealengine.com/t/python-access-to-tsoftobjectptr-property-fails/125922)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_cff3a269](https://forums.unrealengine.com/u/anonymous_user_cff3a269)\
**Replies:** 1\
**Last updated:** [May 10, 2019, 11:33am UTC](https://forums.unrealengine.com/t/python-access-to-tsoftobjectptr-property-fails/125922 "2019-05-10T11:33:17Z")

</div>

I’m trying to modify properties of a data-only blueprint asset which is a child of a C++ custom class. I’m able to successfully read and write all the properties except those of type TSoftObjectPtr. For example: UPRO…

---

## [\[SOLVED\] PYTHON : Cannot get StaticMesh.set\_material() to work](https://forums.unrealengine.com/t/solved-python-cannot-get-staticmesh-set_material-to-work/125851)

<div class="topic-metadata">

**Author:** [@The\_Yojimbo](https://forums.unrealengine.com/u/The_Yojimbo)\
**Replies:** 1\
**Last updated:** [May 9, 2019, 9:57am UTC](https://forums.unrealengine.com/t/solved-python-cannot-get-staticmesh-set_material-to-work/125851 "2019-05-09T09:57:17Z")

</div>

Hello everyone, I’m trying to write a script so I can import lotsa Static Meshes, create material instances out of one parent material and individual textures and assign the material instance to the mesh. I’ve been stu…

---

## [Cant fingure out how to save my inventory items. Please help!](https://forums.unrealengine.com/t/cant-fingure-out-how-to-save-my-inventory-items-please-help/448644)

<div class="topic-metadata">

**Author:** [@Shred\_Hed\_Gaming](https://forums.unrealengine.com/u/Shred_Hed_Gaming)\
**Replies:** 1\
**Last updated:** [May 9, 2019, 9:13am UTC](https://forums.unrealengine.com/t/cant-fingure-out-how-to-save-my-inventory-items-please-help/448644 "2019-05-09T09:13:04Z")

</div>

I have an inventory systen set up that works. I xan save my game and location but xannot figure out how tonsave the items I pickup in the inventory. Please help!

---

## [get the new value in custom event](https://forums.unrealengine.com/t/get-the-new-value-in-custom-event/448499)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_5a5047fa1](https://forums.unrealengine.com/u/anonymous_user_5a5047fa1)\
**Replies:** 2\
**Last updated:** [May 7, 2019, 7:09am UTC](https://forums.unrealengine.com/t/get-the-new-value-in-custom-event/448499 "2019-05-07T07:09:35Z")

</div>

after so many tries finally i found the problem. here i have defined a integer variable in my character BP and i have two menu one for win and one for lose. if player win and press the “next level” that int will added on…

---

## [Save variables from multiple blueprints](https://forums.unrealengine.com/t/save-variables-from-multiple-blueprints/448366)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_f51f8d391](https://forums.unrealengine.com/u/anonymous_user_f51f8d391)\
**Replies:** 3\
**Last updated:** [May 5, 2019, 9:23am UTC](https://forums.unrealengine.com/t/save-variables-from-multiple-blueprints/448366 "2019-05-05T09:23:59Z")

</div>

Hi, I’m looking online for some time at tutorials about saving variable in UE4 and all use the same logic to them. In every tutorial after casting to “save game to slot” the save game object is promoted to a variable i…

---

## [change the variable](https://forums.unrealengine.com/t/change-the-variable/448313)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_5a5047fa1](https://forums.unrealengine.com/u/anonymous_user_5a5047fa1)\
**Replies:** 2\
**Last updated:** [May 4, 2019, 3:33pm UTC](https://forums.unrealengine.com/t/change-the-variable/448313 "2019-05-04T15:33:12Z")

</div>

Hi, i’m new to unreal can anybody help, that how should i connect the variable to switch ? i mean what target for that variable ?

---

## [SaveGame not working?](https://forums.unrealengine.com/t/savegame-not-working/437996)

<div class="topic-metadata">

**Author:** [@OG\_FATFACE\_420](https://forums.unrealengine.com/u/OG_FATFACE_420)\
**Replies:** 30\
**Last updated:** [May 3, 2019, 5:09pm UTC](https://forums.unrealengine.com/t/savegame-not-working/437996 "2019-05-03T17:09:06Z")

</div>

My SaveGame won’t work. I have my blueprint below. So I have a highscore variable, and if a player has a score greater than the highscore, the highscore gets set to that score. I have that blueprint running in user inter…

---

## [Getting a UNavLinkCustomComponent](https://forums.unrealengine.com/t/getting-a-unavlinkcustomcomponent/448250)

<div class="topic-metadata">

**Author:** [@Maniasmurf](https://forums.unrealengine.com/u/Maniasmurf)\
**Replies:** 1\
**Last updated:** [May 3, 2019, 4:11pm UTC](https://forums.unrealengine.com/t/getting-a-unavlinkcustomcomponent/448250 "2019-05-03T16:11:32Z")

</div>

Hi There! I have created a C++ class derived from the NavLinkProxy.cpp and I cannot access the UNavLinkCustomComponent. I really want to get to the LinkRelativeStart and LinkRelativeEnd. Line as follows: UNavLinkCusto…

---

## [VictoryBPPlugin problem with save location in save to file](https://forums.unrealengine.com/t/victorybpplugin-problem-with-save-location-in-save-to-file/448303)

<div class="topic-metadata">

**Author:** [@Qbsoon](https://forums.unrealengine.com/u/Qbsoon)\
**Replies:** 0\
**Last updated:** [May 3, 2019, 12:56pm UTC](https://forums.unrealengine.com/t/victorybpplugin-problem-with-save-location-in-save-to-file/448303 "2019-05-03T12:56:31Z")

</div>

Hi! I’m using “File IO Save String Array to File” from VictoryBPPlugin as save game, beacuse I had problems with using save game object. On PC everything is fine, but I realised that I’ll have a problem with that on And…

---

## [How to find the index inside an array which contains min value?](https://forums.unrealengine.com/t/how-to-find-the-index-inside-an-array-which-contains-min-value/447799)

<div class="topic-metadata">

**Author:** [@bathorysthroat](https://forums.unrealengine.com/u/bathorysthroat)\
**Replies:** 10\
**Last updated:** [April 28, 2019, 8:19am UTC](https://forums.unrealengine.com/t/how-to-find-the-index-inside-an-array-which-contains-min-value/447799 "2019-04-28T08:19:05Z")

</div>

Hi, is there a way to find the index that has the min value inside an Int array? I have built an inventory system much like Resident Evil 2 (remake). Where there is a grid of inventory slots which hold items. I would th…

---

## [Constant array](https://forums.unrealengine.com/t/constant-array/447948)

<div class="topic-metadata">

**Author:** [@megafanat](https://forums.unrealengine.com/u/megafanat)\
**Replies:** 1\
**Last updated:** [April 27, 2019, 4:07am UTC](https://forums.unrealengine.com/t/constant-array/447948 "2019-04-27T04:07:37Z")

</div>

I have a list of 35 predefined values. I want to pick a random value from this list and use it in my game. What is the best way to implement this? I can create a Switch node with 35 outputs and 35 Set nodes. But it look…

---

## [UE\_PYTHON\_DIR does not work for an external python installation on Linux (Ubuntu 18.04)](https://forums.unrealengine.com/t/ue_python_dir-does-not-work-for-an-external-python-installation-on-linux-ubuntu-18-04/124619)

<div class="topic-metadata">

**Author:** [@udnaan](https://forums.unrealengine.com/u/udnaan)\
**Replies:** 2\
**Last updated:** [April 26, 2019, 9:55pm UTC](https://forums.unrealengine.com/t/ue_python_dir-does-not-work-for-an-external-python-installation-on-linux-ubuntu-18-04/124619 "2019-04-26T21:55:29Z")

</div>

Hi, Looking at the source, I can see why. The bundled python source directory structure is modified from original . If that is the expected behavior than it would be nice to document it. It’s assumed that python includ…

---

## [Does Python Scripting work on Linux or not?](https://forums.unrealengine.com/t/does-python-scripting-work-on-linux-or-not/120684)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_89c80c3e](https://forums.unrealengine.com/u/anonymous_user_89c80c3e)\
**Replies:** 3\
**Last updated:** [April 26, 2019, 11:31am UTC](https://forums.unrealengine.com/t/does-python-scripting-work-on-linux-or-not/120684 "2019-04-26T11:31:52Z")

</div>

v4.21.1 compiled from source Basically, enabling the plugin and enabling it in the project appears to have no effect – python isn’t listed as a scripting choice in that drop down, the python menu entries under File neve…

---

## [Editor crash when updating rotation of a precreated spline](https://forums.unrealengine.com/t/editor-crash-when-updating-rotation-of-a-precreated-spline/220389)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_d021988d](https://forums.unrealengine.com/u/anonymous_user_d021988d)\
**Replies:** 0\
**Last updated:** [April 25, 2019, 5:29am UTC](https://forums.unrealengine.com/t/editor-crash-when-updating-rotation-of-a-precreated-spline/220389 "2019-04-25T05:29:51Z")

</div>

Steps: Create a spline through Python programatically. Select the created spline and change the rotation. Notice that a pop up message is displayed and it crashes the editor, post that. Code: actor\_class = unreal.Ed…

---

## [Why do infinite loops in the command line block the editor's UI?](https://forums.unrealengine.com/t/why-do-infinite-loops-in-the-command-line-block-the-editors-ui/447797)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_4636fdcd](https://forums.unrealengine.com/u/anonymous_user_4636fdcd)\
**Replies:** 1\
**Last updated:** [April 24, 2019, 8:29pm UTC](https://forums.unrealengine.com/t/why-do-infinite-loops-in-the-command-line-block-the-editors-ui/447797 "2019-04-24T20:29:26Z")

</div>

I’m using the Python plugin, and by writing an infinite loop (like below) in the console the Unreal Editor UI will block. The Python code with the loop is just: while True: print(0) In fact, what I was trying to d…

---

## [Run python script from Blutility's Execute Python Script](https://forums.unrealengine.com/t/run-python-script-from-blutilitys-execute-python-script/125335)

<div class="topic-metadata">

**Author:** [@kakyoism](https://forums.unrealengine.com/u/kakyoism)\
**Replies:** 0\
**Last updated:** [April 24, 2019, 10:01am UTC](https://forums.unrealengine.com/t/run-python-script-from-blutilitys-execute-python-script/125335 "2019-04-24T10:01:25Z")

</div>

I’m adding a scripted action to Content Browser’s context menu. But it cannot find unreal module, like this LogPython: Error: No module named ‘unreal’ LogPython: Error: Traceback (most recent call last): LogPython: Er…

---

## [Editor crashes when calling AssetTools.find\_soft\_references\_to\_object()](https://forums.unrealengine.com/t/editor-crashes-when-calling-assettools-find_soft_references_to_object/447752)

<div class="topic-metadata">

**Author:** [@kakyoism](https://forums.unrealengine.com/u/kakyoism)\
**Replies:** 0\
**Last updated:** [April 24, 2019, 3:29am UTC](https://forums.unrealengine.com/t/editor-crashes-when-calling-assettools-find_soft_references_to_object/447752 "2019-04-24T03:29:00Z")

</div>

The following Python code crashes my Editor: import unreal as ue source = '/Game/Path/To/MyAsset' at = ue.AssetToolsHelpers().get\_asset\_tools() refs = at.find\_soft\_references\_to\_object(ue.SoftObjectPath(source)) ue.lo…

---

## [SaveGame Pre Construct (autoload logic in bp)](https://forums.unrealengine.com/t/savegame-pre-construct-autoload-logic-in-bp/447624)

<div class="topic-metadata">

**Author:** [@Dreika](https://forums.unrealengine.com/u/Dreika)\
**Replies:** 0\
**Last updated:** [April 22, 2019, 5:21am UTC](https://forums.unrealengine.com/t/savegame-pre-construct-autoload-logic-in-bp/447624 "2019-04-22T05:21:54Z")

</div>

How to add Pre Construct to SaveGame?

[Previous page](https://forums.unrealengine.com/c/development-discussion/pipeline-plugins/editor-scripting/45.md?page=62)

[Next page](https://forums.unrealengine.com/c/development-discussion/pipeline-plugins/editor-scripting/45.md?page=64)
