//This script is the graphical display used for stats in Campaign Instant Action and their wrapup screens s_statlines { GUI_CREATE { location = 0, 0, 10 int bar_height = 5 int stat_val = 0 float loc_val = 0 int nPixelWidth int nSolid = 0 int stat_color = packcolor (0,0,0,255) int id = 0 int nHelpID } GUI_INIT { loc_val = stat_val * (nPixelWidth/100) region = 0,0 to nPixelWidth,bar_height if(!nSolid) { if (stat_val >= 0) and (stat_val < 35) { stat_color = packcolor (200,0,0,255) } else if (stat_val >= 35) and (stat_val < 70) { stat_color = packcolor (200,200,0,255) } else if (stat_val >= 70) and (stat_val <= 100) { stat_color = packcolor (0,200,0,255) } } } REGION_ENTERED { oRollover.nHelpID = nHelpID mail (nMSG_INPUT_RESID,oRollover) } REGION_EXITED { mail (nMSG_CLEARHELP,oRollover) } GUI_DRAW { // firepower lines setpencolor(stat_color) ldrawrect 0,0 to loc_val, bar_height } }