removed all C-style casts
This commit is contained in:
@ -68,28 +68,36 @@ game_command curses_input::get_command() {
|
||||
|
||||
switch (curse->getcmd()) {
|
||||
case 'h':
|
||||
return (game_command)(tmp + west);
|
||||
return static_cast<game_command>
|
||||
(tmp + west);
|
||||
|
||||
case 'j':
|
||||
return (game_command)(tmp + south);
|
||||
return static_cast<game_command>
|
||||
(tmp + south);
|
||||
|
||||
case 'k':
|
||||
return (game_command)(tmp + north);
|
||||
return static_cast<game_command>
|
||||
(tmp + north);
|
||||
|
||||
case 'l':
|
||||
return (game_command)(tmp + east);
|
||||
return static_cast<game_command>
|
||||
(tmp + east);
|
||||
|
||||
case 'y':
|
||||
return (game_command)(tmp + northwest);
|
||||
return static_cast<game_command>
|
||||
(tmp + northwest);
|
||||
|
||||
case 'u':
|
||||
return (game_command)(tmp + northeast);
|
||||
return static_cast<game_command>
|
||||
(tmp + northeast);
|
||||
|
||||
case 'b':
|
||||
return (game_command)(tmp + southwest);
|
||||
return static_cast<game_command>
|
||||
(tmp + southwest);
|
||||
|
||||
case 'n':
|
||||
return (game_command)(tmp + southeast);
|
||||
return static_cast<game_command>
|
||||
(tmp + southeast);
|
||||
|
||||
default:
|
||||
return game_command_panic;
|
||||
|
Reference in New Issue
Block a user