diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2012-05-24 18:53:50 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2012-05-24 18:53:50 (GMT) |
| commit | 8196d2a645d386b5c97134c446e959e5e50a345b (patch) | |
| tree | 33e729715a6122fa5b8dac6f9abf7b784bfbfbc3 /src/elements/nble.c | |
| parent | 5a117c2d27f513942d7621980a79d357af122ba4 (diff) | |
| parent | 1fb778724329782bb5616da032742dce4dbea131 (diff) | |
| download | powder-8196d2a645d386b5c97134c446e959e5e50a345b.zip powder-8196d2a645d386b5c97134c446e959e5e50a345b.tar.gz | |
Merge pull request #66 from jacob1/Modstuff
Code structure improvements for graphics/drawing, improvements to prevent accidental infinite loops in Lua, Fixes for fusion, improvements for VOID types. And other minor improvements
Diffstat (limited to 'src/elements/nble.c')
| -rw-r--r-- | src/elements/nble.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/elements/nble.c b/src/elements/nble.c index bca0291..0c118ed 100644 --- a/src/elements/nble.c +++ b/src/elements/nble.c @@ -25,16 +25,16 @@ int update_NBLE(UPDATE_FUNC_ARGS) float temp = parts[i].temp; part_change_type(i,x,y,PT_PLSM); parts[i].life = rand()%150+50; - j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_NEUT); if (j != -1) - j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_ELEC); if (j != -1) + j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_NEUT); if (j != -1) parts[j].temp = temp; + if (!(rand()%25)) { j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_ELEC); if (j != -1) parts[j].temp = temp; } j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_PHOT); if (j != -1) { parts[j].ctype = 0xFF0000; parts[j].temp = temp; } j = create_part(-3,x+rand()%3-1,y+rand()%3-1,PT_CO2); - if (j != -1) parts[j].temp = temp - 1000; + if (j != -1) parts[j].temp = temp; - parts[i].temp += 10000; - pv[y/CELL][x/CELL] += 30; + parts[i].temp += 1750+rand()%500; + pv[y/CELL][x/CELL] += 50; } } return 0; |
