Guest User

Untitled

a guest
Oct 19th, 2017
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.82 KB | None | 0 0
  1. ClipContext *cc = clip->getContext();
  2.  
  3. tmpusher = this; // PUSH/PULL point source
  4. radius = this->radius; // where force goes to zero
  5. cc->bbox[BOXTOP] = this->y + radius;
  6. cc->bbox[BOXBOTTOM] = this->y - radius;
  7. cc->bbox[BOXRIGHT] = this->x + radius;
  8. cc->bbox[BOXLEFT] = this->x - radius;
  9.  
  10. xl = (cc->bbox[BOXLEFT] - bmaporgx - MAXRADIUS) >> MAPBLOCKSHIFT;
  11. xh = (cc->bbox[BOXRIGHT] - bmaporgx + MAXRADIUS) >> MAPBLOCKSHIFT;
  12. yl = (cc->bbox[BOXBOTTOM] - bmaporgy - MAXRADIUS) >> MAPBLOCKSHIFT;
  13. yh = (cc->bbox[BOXTOP] - bmaporgy + MAXRADIUS) >> MAPBLOCKSHIFT;
  14.  
  15. for (bx = xl; bx <= xh; bx++)
  16. {
  17. for(by = yl; by <= yh; by++)
  18. P_BlockThingsIterator(bx, by, PIT_PushThing, cc);
  19. }
  20.  
  21. cc->done();
Add Comment
Please, Sign In to add comment