mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-07 22:56:30 -10:00
* read access to controls * Early draft of checking keypresses in scpui * detangle some code and prepare it for API usage * API access to the core methods required * move these checks into the UI methods * comment * fix bugs * be smarter * Need this stuff, too * some more presets work * unify func naming scheme * cleanup and clarifications * get detect keypress working * allow searching and creating new presets based on current controls * address feedback * return nil if no preset is matched * use the builtin methods which do the same thing, but slightly cleaner * typo
29 lines
528 B
C++
29 lines
528 B
C++
#pragma once
|
|
|
|
#include "controlconfig/controlsconfig.h"
|
|
#include "scripting/ade_api.h"
|
|
|
|
namespace scripting {
|
|
namespace api {
|
|
|
|
struct control_h {
|
|
int control;
|
|
control_h();
|
|
explicit control_h(int l_control);
|
|
CCI* getControl() const;
|
|
conflict* getConflict() const;
|
|
int getIndex() const;
|
|
};
|
|
|
|
struct preset_h {
|
|
int preset;
|
|
preset_h();
|
|
explicit preset_h(int l_preset);
|
|
CC_preset* getPreset() const;
|
|
};
|
|
|
|
DECLARE_ADE_OBJ(l_Control, control_h);
|
|
DECLARE_ADE_OBJ(l_Preset, preset_h);
|
|
|
|
} // namespace api
|
|
} // namespace scripting
|