Skip to content

Commit

Permalink
Rename [store_relative_dir] to [store_relative_direction]
Browse files Browse the repository at this point in the history
  • Loading branch information
Vultraz committed Apr 17, 2015
1 parent e2b85cf commit 3103fe2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion RELEASE_NOTES
Expand Up @@ -261,7 +261,7 @@ Additionally, you can use "log-debug=scripting/lua" at command line, and all lua
[*] [elseif] inside [if] simplifies wml program flow.
[*] [do_command] allows to execute attacks, moves, recalls, recruits .. from wml having the same effect as if a player had ordered them.
[*] [put_to_recall_list]
[*] [store_relative_dir]
[*] [store_relative_direction]
[*] [remove_event]
[/list]
[/section]
Expand Down
12 changes: 6 additions & 6 deletions src/game_events/action_wml.cpp
Expand Up @@ -1456,21 +1456,21 @@ WML_HANDLER_FUNCTION(sound_source, /*event_info*/, cfg)
}
}

/// Store the relative direction from one hex to antoher in a WML variable.
/// Store the relative direction from one hex to another in a WML variable.
/// This is mainly useful as a diagnostic tool, but could be useful
/// for some kind of scenario.
WML_HANDLER_FUNCTION(store_relative_dir, /*event_info*/, cfg)
WML_HANDLER_FUNCTION(store_relative_direction, /*event_info*/, cfg)
{
if (!cfg.child("source")) {
WRN_NG << "No source in [store_relative_dir]" << std::endl;
WRN_NG << "No source in [store_relative_direction]" << std::endl;
return;
}
if (!cfg.child("destination")) {
WRN_NG << "No destination in [store_relative_dir]" << std::endl;
WRN_NG << "No destination in [store_relative_direction]" << std::endl;
return;
}
if (!cfg.has_attribute("variable")) {
WRN_NG << "No variable in [store_relative_dir]" << std::endl;
WRN_NG << "No variable in [store_relative_direction]" << std::endl;
return;
}

Expand All @@ -1487,7 +1487,7 @@ WML_HANDLER_FUNCTION(store_relative_dir, /*event_info*/, cfg)
}
catch(const invalid_variablename_exception&)
{
ERR_NG << "Cannot do [store_relative_dir] with invalid destination variable: " << variable << " with " << cfg.get_config().debug() << std::endl;
ERR_NG << "Cannot do [store_relative_direction] with invalid destination variable: " << variable << " with " << cfg.get_config().debug() << std::endl;
}
}

Expand Down

0 comments on commit 3103fe2

Please sign in to comment.