Naming Conventions on Variables

I have noticed an annoying little thing that keeps happening when naming variables within blueprints. I use camel-case for my variables, and sometimes the wrong letters are capitalized when I name it.

PlayerHEalth (obviously the E is the wrong case). However, after I submit it and notice the error, I immediately try to rename the variable to PlayerHealth. Once updated, it just returns to PlayerHEalth and it is impossible to correct. Even if I DELETE the variable and start over again, it still remembers my mistake and changes it accordingly.

It’s like UE4 is mocking me and every time I see it it’s like getting kicked right in the apple bag. I know this isn’t a major bug or anything, but it sure is annoying to see a clean list of camel-cased variables on the left and one that sticks out like YouCAntType. Anyone else caught this?

It’s an unfortunate side effect due to the way FNames work, as explained here:

THats a sAd state of AffaIRs.

We’ve made a change for 4.5 which will make FName case-preserving for the editor and UHT. This should address the FName case issues you’ve been seeing.

I’ve checked that you’re able to rename asset, actor, and blueprint components in a way that changes only their case. I’ve also tested that you’re able to have a variables in different UObject/UStruct types that vary only by case, and that the UHT will generate code that actually compiles.