MCPcopy Create free account
hub / github.com/assaultcube/AC / displaycurvalue

Method displaycurvalue

source/src/menus.cpp:596–609  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

594 }
595
596 void displaycurvalue()
597 {
598 if(isradio)
599 {
600 *curval = '\0';
601 loopv(opts) concatformatstring(curval, "%s\1%c %s", i ? " " : "", (i + min_ == value) ? '\11' : '\10', opts[i]);
602 }
603 else if(opts.length()) // extract display name from list
604 {
605 int idx = value - min_;
606 copystring(curval, opts.inrange(idx) ? opts[idx] : "");
607 }
608 else itoa(curval, value); // display number only
609 }
610
611 void getmaxvaluewidth()
612 {

Callers

nothing calls this directly

Calls 5

concatformatstringFunction · 0.85
copystringFunction · 0.85
inrangeMethod · 0.80
loopvFunction · 0.70
lengthMethod · 0.45

Tested by

no test coverage detected