- mitsuruog
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Civic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {call, put, take, fork} from 'redux-saga/effects' | |
import {END} from 'redux-saga' | |
import CategoryActions, {CategoryTypes} from '../Redux/CategoryRedux' | |
// attempts to fetch category | |
export function* fetchCategoryServer (api) { | |
let action = yield take(CategoryTypes.CATEGORY_SERVER) | |
// check when it stopped | |
while (action !== END) { | |
yield fork(fetchCategoryAPI, api) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# firebase-tools/src/commands/init.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
idx = 0 | |
VRMs[idx].vrm.humanoid.humanBones.forEach(({bone, node}) => { | |
console.log(`${bone}: ${VRMs[idx].nodes[node].name}`) | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FirstPersonCamera = pc.createScript('firstPersonCamera'); | |
// initialize code called once per entity | |
FirstPersonCamera.prototype.initialize = function() { | |
// Camera euler angle rotation around x and y axes | |
this.ex = 0; | |
this.ey = 0; | |
// Disabling the context menu stops the browser displaying a menu when | |
// you right-click the page |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Replace2CanvasFont = pc.createScript('replace2canvasFont'); | |
// initialize code called once per entity | |
Replace2CanvasFont.prototype.initialize = function() { | |
this.app.root.findComponents('element').forEach(function(elm){ | |
if(elm.type === 'text') { | |
var font = new pc.CanvasFont(pc.app, { | |
fontName: 'UD Digi Kyokasho N-R, Helvetica, arial, sans-serif', | |
fontSize: 128, | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Replace2CanvasFont = pc.createScript('replace2canvasFont'); | |
// initialize code called once per entity | |
Replace2CanvasFont.prototype.initialize = function() { | |
this.app.root.findComponents('element').forEach(function(elm){ | |
if(elm.type === 'text') { | |
var font = new pc.CanvasFont(pc.app, { | |
fontName: 'UD Digi Kyokasho N-R, Helvetica, arial, sans-serif', | |
fontSize: 128, | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*jshint esversion: 6, asi: true */ | |
const EmojiRandom = pc.createScript('emojiRandom'); | |
// initialize code called once per entity | |
EmojiRandom.prototype.initialize = function() { | |
setInterval(() => { | |
const emojiCode = Math.floor(Math.random() * (129685 - 129660 + 1) + 129660); | |
const emoji = String.fromCodePoint(emojiCode) | |
console.log(emoji) | |
this.app.fire("text:set", this.entity.element, emoji) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.chat{ | |
width: 300px; | |
padding: 0.5rem; | |
border-radius: 0.5rem; | |
border: 1px solid; | |
background: white; | |
} | |
.header{ |
OlderNewer