Advertisement
Guest User

Untitled

a guest
Jan 20th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.17 KB | None | 0 0
  1. publics: LoadPlantsCallBack()
  2. {
  3. if(!cache_num_rows())
  4. {
  5. printf("-> Не удалось загрузить кусты");
  6. return true;
  7. }
  8. for(new i=0; i < cache_num_rows(); i++) {
  9. PlantInfo[i][plant_id] = cache_get_field_content_int(i, "id");
  10. PlantInfo[i][plant_status] = cache_get_field_content_int(i, "item_id");
  11. PlantInfo[i][plant_prog] = cache_get_field_content_int(i, "item_quantity");
  12. PlantInfo[i][plant_owner] = cache_get_field_content_int(i, "dropped_by");
  13. PlantInfo[i][plant_pos][0] = cache_get_field_content_float(i, "pos_x");
  14. PlantInfo[i][plant_pos][1] = cache_get_field_content_float(i, "pos_y");
  15. PlantInfo[i][plant_pos][2] = cache_get_field_content_float(i, "pos_z");
  16. PlantInfo[i][plant_vw] = cache_get_field_content_int(i, "vw");
  17. PlantInfo[i][plant_int] = cache_get_field_content_int(i, "int");
  18.  
  19. PlantInfo[i][plant_obj_id] = CreateDynamicObject(19473, PlantInfo[i][plant_pos][0], PlantInfo[i][plant_pos][1], PlantInfo[i][plant_pos][2]-1.2, 0.0, 0.0, 0.0, PlantInfo[i][plant_vw], PlantInfo[i][plant_int], -1, 150);
  20. CreatePlant3DText(i);
  21. }
  22. printf("-> Кустов загружено: %d", cache_num_rows());
  23. return true;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement