File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11#include " simulation/ElementCommon.h"
22#include " FILT.h"
3+ #include " PAPR.h"
34
45static int update (UPDATE_FUNC_ARGS);
56static bool ctypeDraw (CTYPEDRAW_FUNC_ARGS);
@@ -122,6 +123,21 @@ static int update(UPDATE_FUNC_ARGS)
122123 else if (colored==0xFF000000 )
123124 colored = 0 ;
124125 parts[ID (r)].life = 4 ;
126+ } else if (TYP (r) == PT_PAPR) {
127+ if (TYP (parts[i].ctype == PT_COAL) || TYP (parts[i].ctype ) == PT_BCOL) {
128+ sim->parts [ID (r)].life = 1 ;
129+ if (colored)
130+ sim->parts [ID (r)].dcolour = colored;
131+ else
132+ sim->parts [ID (r)].dcolour = MARK_COLOR_COAL;
133+ if (!--partsRemaining)
134+ docontinue = 0 ;
135+ } else if (TYP (parts[i].ctype == PT_SOAP)) {
136+ sim->parts [ID (r)].life = 0 ;
137+ sim->parts [ID (r)].dcolour = 0x00000000 ;
138+ if (!--partsRemaining)
139+ docontinue = 0 ;
140+ }
125141 } else if (TYP (r) == PT_CRAY || nostop) {
126142 docontinue = 1 ;
127143 } else if (destroy && r && (TYP (r) != PT_DMND)) {
Original file line number Diff line number Diff line change 11#include " simulation/ElementCommon.h"
2+ #include " PAPR.h"
23
34static int update (UPDATE_FUNC_ARGS);
45static int graphics (GRAPHICS_FUNC_ARGS);
@@ -86,7 +87,7 @@ static int update(UPDATE_FUNC_ARGS)
8687 // Get marked by BCOL
8788 case PT_BCOL:
8889 parts[i].life = 1 ;
89- parts[i].dcolour = 0xFF22222A ;
90+ parts[i].dcolour = MARK_COLOR_COAL ;
9091 break ;
9192
9293 // Acts as a smoke filter
@@ -205,7 +206,7 @@ static bool ctypeDraw(CTYPEDRAW_FUNC_ARGS)
205206 if (t == PT_BCOL || t == PT_COAL)
206207 {
207208 sim->parts [i].life = 1 ;
208- sim->parts [i].dcolour = 0xFF22222A ;
209+ sim->parts [i].dcolour = MARK_COLOR_COAL ;
209210 }
210211 // Similarly, erase with SOAP
211212 if (t == PT_SOAP)
Original file line number Diff line number Diff line change 1+ #pragma once
2+
3+ constexpr unsigned int MARK_COLOR_COAL = 0xFF22222A ;
You can’t perform that action at this time.
0 commit comments