Unreal Engine (on Mac) adds // Fill out your copyright notice in the Description page of Project Settings. on each code file. I changed my copyright notice on that page but it doesn’t change on the files. What to do?
Once you have set that in the UE4 editor, it should apply the changes the next time you compile your project in Visual Studio (or Xcode), you may need to restart your code editor for the changes to appear.
If that’s not the case can you let us know which engine version you are using?
I’am having the same problem as CrispyTutleAlligator. Unreal Engine 4.12.5 on Windows.
Save problem. Unreal Engine 4.12.5, Windows, Visual Studio 2015
Same problem here too. UE 4.12.5 with VS2015.
Same problem here. UE 4.13.1 on windows 10.
Further testing shows that setting the copyright notice on the editor will not update any of the existing source files; however, it will put the copyright notice on the newly created ones through the editor (such as when creating a c++ class). Not sure whether this is how it is supposed to work.
Ive written a very shabby python script for this issue. Altough 7 years too late, the issue still persists.
How it works:
This script runs trough ALL files in the source folder, checks if the first two symbols in the first line of the file are “//” and then replaces the line with the copyright you set in the editor.
Your folder structure MUST look like this:
- Config
– DefaultGame.ini - Scripts (you need to manually add this folder and put the script in it)
– UpdateCopyright.py - Source
Before you run the script, make sure to commit your changes or make a backup if unwanted changes appear.
To run the script you either need to install python or use py2exe and convert it.
Thats it - run the script whenever you make changes to the copyright notice in the editor (or DefaultGame.ini).
UpdateCopyright.py (1.5 KB)
PS: Wrote this script in 10 minutes, never used Python before, so please dont judge me. You are free to use, modify and everything else.