mirror of https://github.com/nmlgc/ReC98.git
24 lines
394 B
C++
24 lines
394 B
C++
// Shared input implementation macros.
|
|
|
|
#define on_condition_if_not_locked(condition, lock, func) { \
|
|
if(condition) { \
|
|
if(lock == false) { \
|
|
func \
|
|
} \
|
|
lock = true; \
|
|
} else { \
|
|
lock = false; \
|
|
} \
|
|
}
|
|
|
|
#define on_condition_if_not_locked_2(condition, lock, func) { \
|
|
if(condition) { \
|
|
if(lock == false) { \
|
|
func \
|
|
lock = true; \
|
|
} \
|
|
} else { \
|
|
lock = false; \
|
|
} \
|
|
}
|