diff --git a/include/files.h b/include/files.h new file mode 100644 index 0000000..25f438d --- /dev/null +++ b/include/files.h @@ -0,0 +1,15 @@ +// this code is licenced under Wrathmark licence +// © 2026 wullie wulliestudio.com +// please see attached licence for full usage and rights + +#ifndef FILES_h +#define FILES_h + +// file handling +long Wopen(const char *pathname, int flags, int mode); +long closeFile(long fd); +long reader(long fd, char *string); +long mkdir(const char *filePath, int mode); + + +#endif diff --git a/include/math.h b/include/math.h new file mode 100644 index 0000000..06d7405 Binary files /dev/null and b/include/math.h differ diff --git a/include/stdWullie.h b/include/stdWullie.h index 9ee954a..e7dea79 100644 --- a/include/stdWullie.h +++ b/include/stdWullie.h @@ -2,30 +2,9 @@ // © 2026 wullie wulliestudio.com // please see attached licence for full usage and rights -#ifndef MIAN_h +#ifndef MAIN_h #define MAIN_h -// ANSI colors -// foreground -#define BLACK "\x1b[30m" -#define RED "\x1b[31m" -#define GREEN "\x1b[32m" -#define YELLOW "\x1b[33m" -#define BLUE "\x1b[34m" -#define MAGENTA "\x1b[35m" -#define CYAN "\x1b[36m" -#define WHITE "\x1b[37m" -#define NORMAL "\x1b[m" - -// background -#define BBLACK "\x1b[40m" -#define BRED "\x1b[41m" -#define BGREEN "\x1b[42m" -#define BYELLOW "\x1b[43m" -#define BBLUE "\x1b[44m" -#define BMAGENTA "\x1b[45m" -#define BCYAN "\x1b[46m" -#define BWHITE "\x1b[47m" // gay ass glibc shit why in the fuck does this exist like that #undef NULL @@ -35,22 +14,9 @@ #define true 1 #define false 0 - - -// text functions -void ColorPrint(char *string, char *color); -void BackgroundPrint(char *string, char *Bcolor); -void print(char *string); -// strlen implemenation -long unsigned lengthStr(char *string); -void upper(char string[]); -void lower(char string[]); - -// file handling -long Wopen(const char *pathname, int flags, int mode); -long closeFile(long fd); -long reader(long fd, char *string); -long mkdir(const char *filePath, int mode); +// import tree +#include "string.h" +#include "files.h" // memory void Wmalloc(); @@ -64,6 +30,9 @@ void riskyError(); // math int intParser(char *rawInt); float invSqrt(float x); +float floatPow(float base, int exponant); +int intPow(int base, int exponant0); + // misc void sleeper(long seconds); diff --git a/include/string.h b/include/string.h new file mode 100644 index 0000000..5723561 --- /dev/null +++ b/include/string.h @@ -0,0 +1,46 @@ +// this code is licenced under Wrathmark licence +// © 2026 wullie wulliestudio.com +// please see attached licence for full usage and rights + +#ifndef STRING_h +#define STRING_h + +// ANSI colors +// foreground +#define BLACK "\x1b[30m" +#define RED "\x1b[31m" +#define GREEN "\x1b[32m" +#define YELLOW "\x1b[33m" +#define BLUE "\x1b[34m" +#define MAGENTA "\x1b[35m" +#define CYAN "\x1b[36m" +#define WHITE "\x1b[37m" +#define NORMAL "\x1b[m" + +// background +#define BBLACK "\x1b[40m" +#define BRED "\x1b[41m" +#define BGREEN "\x1b[42m" +#define BYELLOW "\x1b[43m" +#define BBLUE "\x1b[44m" +#define BMAGENTA "\x1b[45m" +#define BCYAN "\x1b[46m" +#define BWHITE "\x1b[47m" + +// printing +void ColorPrint(char *string, char *color); +void BackgroundPrint(char *string, char *Bcolor); +void print(char *string); + +long unsigned lengthStr(char *string); + +// conversion +void upper(char string[]); +void lower(char string[]); +const char *intCon(int num); + + +void input(); + +#endif +