Compare commits

...
2 Commits
Author SHA1 Message Date
Pierre e7cd82c720 merged? 2026-09-30 22:56:09 +02:00
Pierre 9fcf86cbbf start of electromagnetism Tesla would be proud 2026-09-30 22:26:06 +02:00
2 changed files with 6 additions and 0 deletions

No files matched your search

+5
View File
@@ -3,7 +3,11 @@
#include "consts.h"
#include "gravity.h"
#include "mechanics.h"
<<<<<<< HEAD
#include "magnetism.h"
=======
#include "objects.h"
>>>>>>> aa4f0dfe52bab37ef3bf82a47c44316c74c3ccbc
#include <bits/time.h>
#include <math.h>
#include <pthread.h>
@@ -35,6 +39,7 @@ void *physics(void *args) {
clock_gettime(CLOCK_MONOTONIC, &ct);
// gravity(uni);
mechanics(uni);
magnetism(uni);
ot = ct;
long long elapsed = timespec_diff_ns(ct, ot);
long long remaining = TIMESTEP / simx - elapsed;
+1
View File
@@ -7,6 +7,7 @@ typedef struct {
float radius;
Vector2 position;
Vector2 speed;
float charge;
} mass_body_t;
typedef struct universe {