Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Explanation on plugins and generated code.

Currently reading this guide on plugins: https://docs.unrealengine.com/latest/INT/Programming/Plugins/

This paragraph caught my eye.

Plugins are allowed to declare new UObject types (UCLASS, USTRUCT, etc) in header files in a Classes subdirectory in their module code folders. The Unreal Engine build system will detect these files and generate code as needed to support these UObjects. You will need to follow the normal rules for using UObjects within C++ modules, such as including the generated header file and the module's generated.inl file in one of your module's source files.

What code would the engine need to build to support the uobjects?

Product Version: UE 4.12
more ▼

asked Jun 19 '16 at 12:26 PM in C++ Programming

avatar image

37 7 9 11

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Thsi docs seems to confuse you. If you did UE4 C++ project and you can do something there, you are already know how to make plugin... you simply not aware of it yet :p Let me explain...

UE4 code is divided in to modules (if you ever seen Linux kernel modules, they work in similar manner), each module contain specific feature (or part of it) and each loaded extends the engine itself. When you create C++ project, it create project and extra code module, that code module is not diffrent from what any engine module, it work exactly the same way, you can do exactly same things and you technically extending engine code by adding game code in to it to make all things work. Explore engine source code, you will notice that the way code is structured is not much different from what you see in C++. Same goes with plugins, it just diffrent way of distributing modules, your plugin directory works exactly the same as C++ project directory, aspecially Source directory, you can move the code form C++ project and it will work same way (ofcorse you would need to fix names and stuff :p).

So if you done anything on UE4 with C++ you already know how to make plugins... you just need to learn different thing which is extending editor if you interested on that, and you can do some from anywhere C++ game project too, plugin just makes code usable on different projects. Sadly that is not very well documented and most stuff you will need to search thru community tutorials (in UE4 wiki for example) or by looking up in engine source code to see how things in editor are coded.

You also seem to not understand what UObject is, it a root class that most classes inherent from (this includes all Actors) all those classes are classified as UObjects. Those classes are managed by reflection system and overlal UE4 memoery managment system, UE4 simply register, monitor and manage them all the time online normal C++ classes which are not visible to the engine. Look in "Class Viewer" in editor (Windows->Devloper Tools->Class Viewer) it will show you inherence tree of all UObject classes in the engine and if you disable all filters you will see everything ultimately inherence from Object class. You already used UObjects if you used C++ game project :p

Also importent note, UBT (UE4 build system) need to informed to comple module, there is a list of modules where you need to add them, in C++ game project you have them listed in uproject file and plugin you got them in uplugin file. UE4 will automaticly add one if you do C++ game project, or use that plugin generator

If you extend editor (you interact in editor code in any way, except Slate salte cna work without editor), you need to place editor code in sperate module and mark it as editor module. Really loook up how other editor plugins are made to see what i mean.


more ▼

answered Jun 19 '16 at 03:20 PM

avatar image

35.9k 928 169 1105

avatar image Sheeplie Jul 07 '16 at 01:42 AM

Hey there- I know I'm a bit late, but I got the chance to come back and read everything. Thank you, legitimately, for the detailed explanation. I'll definitely take a look at some editor plugins as that's where I'd eventually like to head. Thanks again.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question