rename stretch* to reach*
This commit is contained in:
parent
f7366b780f
commit
eac7c9c411
9
dyrect.h
9
dyrect.h
@ -17,7 +17,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
// TODO: further macro hell x, y, width and height so they can be user overwritten too
|
// TODO: further macro hell x, y, width and height so they can be user overwritten too
|
||||||
// TODO: stretch(x|y) naming is meh
|
|
||||||
// TODO: theres a logical inconsistency between ride-hang and rock-paper; either justify it or normalize it
|
// TODO: theres a logical inconsistency between ride-hang and rock-paper; either justify it or normalize it
|
||||||
|
|
||||||
|
|
||||||
@ -83,8 +82,8 @@ static inline rect_t rock(rect_t dest, rect_t source);
|
|||||||
static inline rect_t paper(rect_t dest, rect_t source);
|
static inline rect_t paper(rect_t dest, rect_t source);
|
||||||
static inline rect_t next(rect_t source, int n);
|
static inline rect_t next(rect_t source, int n);
|
||||||
static inline rect_t after(rect_t source, int n);
|
static inline rect_t after(rect_t source, int n);
|
||||||
static inline rect_t stretchy(rect_t dest, rect_t source);
|
static inline rect_t reachy(rect_t dest, rect_t source);
|
||||||
static inline rect_t stretchx(rect_t dest, rect_t source);
|
static inline rect_t reachx(rect_t dest, rect_t source);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -364,7 +363,7 @@ rect_t after(rect_t source, int n) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline
|
static inline
|
||||||
rect_t stretchy(rect_t dest, rect_t source) {
|
rect_t reachy(rect_t dest, rect_t source) {
|
||||||
return (dest.y > source.y) ?
|
return (dest.y > source.y) ?
|
||||||
(rect_t) {
|
(rect_t) {
|
||||||
.x = source.x,
|
.x = source.x,
|
||||||
@ -383,7 +382,7 @@ rect_t stretchy(rect_t dest, rect_t source) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline
|
static inline
|
||||||
rect_t stretchx(rect_t dest, rect_t source) {
|
rect_t reachx(rect_t dest, rect_t source) {
|
||||||
return (dest.x > source.x) ?
|
return (dest.x > source.x) ?
|
||||||
(rect_t) {
|
(rect_t) {
|
||||||
.x = source.x,
|
.x = source.x,
|
||||||
|
@ -13,7 +13,7 @@ void do_resize(void) {
|
|||||||
hotbar = ride(after(get_screen_rect(), 1), scaley(get_screen_rect(), 0.17f));
|
hotbar = ride(after(get_screen_rect(), 1), scaley(get_screen_rect(), 0.17f));
|
||||||
healt = ride(after(get_screen_rect(), 1), scale(get_unit_rect(), hotbar.height * 1.2f));
|
healt = ride(after(get_screen_rect(), 1), scale(get_unit_rect(), hotbar.height * 1.2f));
|
||||||
manna = paper(hotbar, healt);
|
manna = paper(hotbar, healt);
|
||||||
inventory = stretchy(hotbar, paper(get_screen_rect(), scalex(get_screen_rect(), 0.5f)));
|
inventory = reachy(hotbar, paper(get_screen_rect(), scalex(get_screen_rect(), 0.5f)));
|
||||||
inventory_inner = buoyance(inventory, scale(inventory, 0.8f));
|
inventory_inner = buoyance(inventory, scale(inventory, 0.8f));
|
||||||
inventory_slot = rock(inventory_inner, hang(inventory_inner, scale(get_unit_rect(), inventory_inner.width / 9)));
|
inventory_slot = rock(inventory_inner, hang(inventory_inner, scale(get_unit_rect(), inventory_inner.width / 9)));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user