Merge branch 'feature-tabletop' into develop
This commit is contained in:
49
app/imports/api/tabletop/TabletopMaps.js
Normal file
49
app/imports/api/tabletop/TabletopMaps.js
Normal file
@@ -0,0 +1,49 @@
|
||||
import SimpleSchema from 'simpl-schema';
|
||||
import ChildSchema from '/imports/api/parenting/ChildSchema.js';
|
||||
|
||||
let TabletopMaps = new Mongo.Collection('tabletopmaps');
|
||||
|
||||
let TabletopMapschema = new SimpleSchema({
|
||||
name: {
|
||||
type: String,
|
||||
optional: true,
|
||||
},
|
||||
texture: {
|
||||
type: String,
|
||||
regEx: SimpleSchema.RegEx.Id,
|
||||
},
|
||||
position: {
|
||||
type: Object,
|
||||
optional: true,
|
||||
},
|
||||
'position.x': {
|
||||
type: Number,
|
||||
},
|
||||
'position.y': {
|
||||
type: Number,
|
||||
},
|
||||
width: {
|
||||
type: Number,
|
||||
},
|
||||
height: {
|
||||
type: Number,
|
||||
},
|
||||
rotation: {
|
||||
type: Number,
|
||||
max: 360,
|
||||
min: 0,
|
||||
},
|
||||
// If this map was copied from a library map, this ID will be set
|
||||
libraryMapId: {
|
||||
type: String,
|
||||
regEx: SimpleSchema.RegEx.Id,
|
||||
optional: true,
|
||||
},
|
||||
});
|
||||
|
||||
const schema = new SimpleSchema({});
|
||||
schema.extend(ChildSchema);
|
||||
schema.extend(TabletopMapschema);
|
||||
TabletopMaps.attachSchema(schema);
|
||||
|
||||
export default TabletopMaps;
|
||||
43
app/imports/api/tabletop/TabletopObjects.js
Normal file
43
app/imports/api/tabletop/TabletopObjects.js
Normal file
@@ -0,0 +1,43 @@
|
||||
import SimpleSchema from 'simpl-schema';
|
||||
import ChildSchema from '/imports/api/parenting/ChildSchema.js';
|
||||
|
||||
let TabletopObjects = new Mongo.Collection('tabletopObjects');
|
||||
|
||||
let TabletopObjectSchema = new SimpleSchema({
|
||||
name: {
|
||||
type: String,
|
||||
optional: true,
|
||||
},
|
||||
texture: {
|
||||
type: String,
|
||||
regEx: SimpleSchema.RegEx.Id,
|
||||
},
|
||||
position: {
|
||||
type: Object,
|
||||
optional: true,
|
||||
},
|
||||
'position.x': {
|
||||
type: Number,
|
||||
},
|
||||
'position.y': {
|
||||
type: Number,
|
||||
},
|
||||
width: {
|
||||
type: Number,
|
||||
},
|
||||
height: {
|
||||
type: Number,
|
||||
},
|
||||
rotation: {
|
||||
type: Number,
|
||||
max: 360,
|
||||
min: 0,
|
||||
},
|
||||
});
|
||||
|
||||
const schema = new SimpleSchema({});
|
||||
schema.extend(ChildSchema);
|
||||
schema.extend(TabletopObjectSchema);
|
||||
TabletopObjects.attachSchema(schema);
|
||||
|
||||
export default TabletopObjects;
|
||||
1253
app/imports/api/tabletop/three/OrbitControls.js
Normal file
1253
app/imports/api/tabletop/three/OrbitControls.js
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user