You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

32 lines
998 B

5 years ago
5 years ago
5 years ago
5 years ago
  1. #ifndef MINDUSTRY_H
  2. #define MINDUSTRY_H
  3. struct MindustryObject {};
  4. // void _asm(char* code);
  5. // builtin instructions
  6. void print(char* s);
  7. void printd(double s);
  8. void printflush(struct MindustryObject msg_block);
  9. struct MindustryObject radar(struct MindustryObject obj, char* target1, char* target2,
  10. char* target3, char* sort, double index);
  11. double sensor(struct MindustryObject obj, char* prop);
  12. void enable(struct MindustryObject obj, double enabled);
  13. void shoot(struct MindustryObject obj, double x, double y, double shoot);
  14. void end();
  15. // builtin binary operators
  16. double pow(double x, double y);
  17. double max(double x, double y);
  18. double min(double x, double y);
  19. double atan2(double x, double y);
  20. double dst(double x, double y);
  21. // builtin unary operators
  22. double abs(double x);
  23. double log(double x);
  24. double log10(double x);
  25. double sin(double x);
  26. double cos(double x);
  27. double tan(double x);
  28. double floor(double x);
  29. double ceil(double x);
  30. double sqrt(double x);
  31. double rand(double x);
  32. #endif