diff options
Diffstat (limited to '')
| -rw-r--r-- | src/esp.cpp | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/src/esp.cpp b/src/esp.cpp index aa9f645..51f46bc 100644 --- a/src/esp.cpp +++ b/src/esp.cpp | |||
| @@ -1573,18 +1573,26 @@ void esp_draw() { | |||
| 1573 | const char *tag = nullptr; | 1573 | const char *tag = nullptr; |
| 1574 | int tr = 255, tg = 255, tb = 255; | 1574 | int tr = 255, tg = 255, tb = 255; |
| 1575 | if (t.damage == NPC_DMG_ARMORED) { | 1575 | if (t.damage == NPC_DMG_ARMORED) { |
| 1576 | tag = "ARMORED"; | 1576 | tag = "ARM"; |
| 1577 | tr = 255; tg = 170; tb = 60; | 1577 | tr = 255; tg = 170; tb = 60; |
| 1578 | } else if (t.damage == NPC_DMG_VULNERABLE) { | 1578 | } else if (t.damage == NPC_DMG_VULNERABLE) { |
| 1579 | tag = "VULN"; | 1579 | tag = "VULN"; |
| 1580 | tr = 90; tg = 220; tb = 255; | 1580 | tr = 90; tg = 220; tb = 255; |
| 1581 | } else if (t.damage == NPC_DMG_IMMUNE) { | 1581 | } else if (t.damage == NPC_DMG_IMMUNE) { |
| 1582 | tag = "IMMUNE"; | 1582 | tag = "IMM"; |
| 1583 | tr = 180; tg = 180; tb = 180; | 1583 | tr = 180; tg = 180; tb = 180; |
| 1584 | } | 1584 | } |
| 1585 | if (tag) | 1585 | if (tag) { |
| 1586 | draw_text_col(left, top - (esp_option(ESP_OPT_SHOW_NAME) ? 28 : 14), | 1586 | // Small label on the left edge of the box, black 1px shadow for |
| 1587 | tag, tr, tg, tb); | 1587 | // readability against the world (the 10px ESP font). |
| 1588 | int tw = (int)strlen(tag) * 6; | ||
| 1589 | int tx = left - tw - 3; | ||
| 1590 | if (tx < 2) | ||
| 1591 | tx = 2; | ||
| 1592 | int ty = top + 2; | ||
| 1593 | draw_text_small_col(tx + 1, ty + 1, tag, 0, 0, 0); | ||
| 1594 | draw_text_small_col(tx, ty, tag, tr, tg, tb); | ||
| 1595 | } | ||
| 1588 | } | 1596 | } |
| 1589 | } | 1597 | } |
| 1590 | 1598 | ||
