Guest User

Untitled

a guest
Jan 21st, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. int i;
  2. for (i = 0; i < openborvariant("count_entities"); ++i)
  3. {
  4. // If we on an odd box, don't do anything.
  5. if(i % 2)
  6. {
  7. continue;
  8. }
  9.  
  10. void ent = getentity(i);
  11. char name = getentityproperty(ent,"defaultname");
  12. if ( getentityproperty(ent, "exists") && name == "box" )
  13. {
  14. int sort = getentityproperty(ent,"sortid");
  15. sort++;
  16. changeentityproperty(ent,"sortid", sort);
  17. }
  18. }
Add Comment
Please, Sign In to add comment