Skip to content

Commit

Permalink
Move emscripten files
Browse files Browse the repository at this point in the history
  • Loading branch information
robertlong committed Feb 9, 2023
1 parent ea76a45 commit a56e4f3
Show file tree
Hide file tree
Showing 103 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
src/asset-pipeline/vendor
src/logviewer
src/scripting
src/engine/scripting/emscripten
public/
examples/
2 changes: 1 addition & 1 deletion examples/interactable/c/src/interactable-example.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#include "../../../../src/scripting/src/generated/websg.h"
#include "../../../../src/engine/scripting/emscripten/src/generated/websg.h"

export void *websg_allocate(int size) {
return malloc(size);
Expand Down
4 changes: 2 additions & 2 deletions examples/network/c/src/networked-example.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#include "../../../../src/scripting/src/generated/websg.h"
#include "../../../../src/scripting/src/network.h"
#include "../../../../src/engine/scripting/emscripten/src/generated/websg.h"
#include "../../../../src/engine/scripting/emscripten/src/network.h"

int PACKET_BYTES = 3;

Expand Down
4 changes: 2 additions & 2 deletions examples/procgen/c/src/procgen.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
#include <emscripten/console.h>
#define FNL_IMPL
#include "./FastNoiseLite.h"
#include "../../../../src/scripting/src/generated/websg.h"
#include "../../../../src/scripting/src/thirdroom.h"
#include "../../../../src/engine/scripting/emscripten/src/generated/websg.h"
#include "../../../../src/engine/scripting/emscripten/src/thirdroom.h"

#define MIN(a,b) (((a)<(b))?(a):(b))
#define MAX(a,b) (((a)>(b))?(a):(b))
Expand Down
4 changes: 2 additions & 2 deletions examples/widget-hello-world/c/src/widget-example.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
#include <stdlib.h>
#include <stdbool.h>
#include <string.h>
#include "../../../../src/scripting/src/generated/websg.h"
#include "../../../../src/scripting/src/matrix.h"
#include "../../../../src/engine/scripting/emscripten/src/generated/websg.h"
#include "../../../../src/engine/scripting/emscripten/src/matrix.h"

export void *websg_allocate(int size) {
return malloc(size);
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"test": "vitest",
"test:ui": "vitest --ui",
"coverage": "vitest run --coverage",
"generate": "vite-node ./src/engine/resource/codegen.ts"
"generate": "vite-node ./src/engine/scripting/codegen.ts"
},
"dependencies": {
"3d-tiles-renderer": "https://github.com/matrix-org/3DTilesRendererJS.git#v0.3.9-patch",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import { TypedArrayConstructor32 } from "../utils/typedarray";
import camelToSnakeCase from "../utils/camelToSnakeCase";
import kebabToPascalCase from "../utils/kebabToPascalCase";
import kebabToSnakeCase from "../utils/kebabToSnakeCase";
import { ResourceDefinition, ResourcePropDef } from "./ResourceDefinition";
import * as SchemaModule from "./schema";
import { ResourceDefinition, ResourcePropDef } from "../resource/ResourceDefinition";
import * as SchemaModule from "../resource/schema";
import camelToPascalCase from "../utils/camelToPascalCase";

const __filename = fileURLToPath(import.meta.url);
Expand Down Expand Up @@ -845,7 +845,7 @@ void js_define_websg_api(JSContext *ctx, JSValue *global);
}

async function main() {
const outDir = path.resolve(__dirname, "../../scripting/src/generated");
const outDir = path.resolve(__dirname, "./emscripten/src/generated");

if (existsSync(outDir)) {
await rm(outDir, { recursive: true });
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit a56e4f3

Please sign in to comment.