diff options
| author | jacksonmj <mj-pt@jacksonmj.co.uk> | 2012-01-18 19:07:56 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2012-02-05 14:45:29 (GMT) |
| commit | a722d7a396e4cad8caa5bfa8bfed47a6ec59a016 (patch) | |
| tree | 08095ba053a90828f07bcbf3c208aa109131dc9a /src/elements | |
| parent | 6bdc05cc40a89b6454fdbaca7a2315a07f085bf9 (diff) | |
| download | powder-a722d7a396e4cad8caa5bfa8bfed47a6ec59a016.zip powder-a722d7a396e4cad8caa5bfa8bfed47a6ec59a016.tar.gz | |
Change wifi so that it always takes one frame to transmit
Diffstat (limited to 'src/elements')
| -rw-r--r-- | src/elements/wifi.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/elements/wifi.c b/src/elements/wifi.c index 3e87fef..55d151d 100644 --- a/src/elements/wifi.c +++ b/src/elements/wifi.c @@ -12,6 +12,8 @@ int update_WIFI(UPDATE_FUNC_ARGS) { r = pmap[y+ry][x+rx]; if (!r) continue; + // wireless[][0] - whether channel is active on this frame + // wireless[][1] - whether channel should be active on next frame if (wireless[parts[i].tmp][0]) { if (((r&0xFF)==PT_NSCN||(r&0xFF)==PT_PSCN||(r&0xFF)==PT_INWR)&&parts[r>>8].life==0 && wireless[parts[i].tmp][0]) @@ -25,9 +27,8 @@ int update_WIFI(UPDATE_FUNC_ARGS) { { if ((r&0xFF)==PT_SPRK && parts[r>>8].ctype!=PT_NSCN && parts[r>>8].life>=3) { - wireless[parts[i].tmp][0] = 1; wireless[parts[i].tmp][1] = 1; - ISWIRE = 1; + ISWIRE = 2; } } } |
