x

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"

At runtime, removing a default mapping without adding a new one does not result in a modified Input.ini

I'm working on a input configuration system for my game, and I've hit a bit of a snag. The system is set up to collect changes to the input config, then save them all at once. This works fine except when the player makes a change that only contains removal of default mappings/config. Adding new ones works. Removing defaults and adding customs in the same save works. Adding customs, saving, then removing those customs works. But as soon as the only change is going to a subset of the default configuration, the entire section (AxisMapping, ActionMapping, or AxisConfig) gets blasted. If the player proceeds playing the game, everything works fine. However, once the game is closed, those changes are lost. This is the case for all three sections, too. Here's an example of one of my removal functions:

 bool UInputConfig::RemoveActionMapping(FName actionName, FKey oldKey, bool ctrl, bool shift, bool alt, bool cmd)
 {
     UInputSettings* Settings = UInputSettings::StaticClass()->GetDefaultObject<UInputSettings>();
     if (!Settings) return false;

     FInputActionKeyMapping oldAction(actionName, oldKey, shift, ctrl, alt, cmd);
     Settings->RemoveActionMapping(oldAction);

     return true;
 }
Product Version: UE 4.8
Tags:
more ▼

asked Aug 25 '15 at 08:05 PM in C++ Programming

avatar image

Pixley
16 2 3

avatar image clugo Apr 25 '17 at 08:58 AM

I know that this is a old question, but I have the same problem. I'm trying to remove all ActionMapping from Input.ini to force the engine to reload the defaults input from DefaultInput.ini, but nothing works.

Did you find any solution about this?

Thanks!

avatar image Pixley Apr 25 '17 at 05:17 PM

No. We've let the issue sit in the intervening time. It's still really annoying, though.

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

0 answers: sort voted first
Be the first one to answer this question
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