Commit 9a90fb5b authored by 18손재민's avatar 18손재민

새 폰트 적용함

parent 2dc1644b
......@@ -17,6 +17,16 @@
<script src="js/Enums.js"></script>
<script src="js/ResourceLoader.js"></script>
<script src="js/UIObject.js"></script>
<style media='screen' type='text/css'>
@font-face {
font-family: sejongFont;
src: url('assets/font/EBS주시경B.ttf');
font-weight:400;
font-weight:normal;
}
</style>
<div style="font-family:sejongFont; position:absolute; left:-1000px; visibility:hidden;">.</div>
<style>
img { position: relative; width: 100%; height: 100%; z-index: 0;}
......
......@@ -122,7 +122,7 @@ var menuScene = new Phaser.Class(
background: this.add.sprite(game.config.width / 2, game.config.height / 2, 'panel').setOrigin(0.5, 0.5),
content: this.add.text(0, 0, '대기실에 참가하시겠습니까?', {
font: '50pt 궁서'
font: '50pt sejongFont'
}),
actions: [
......@@ -231,7 +231,7 @@ var hopaeScene = new Phaser.Class(
background: this.add.sprite(game.config.width / 2, game.config.height / 2, 'panel').setOrigin(0.5, 0.5),
content: this.add.text(0, 0, '이 이름으로 하시겠습니까?' + (PlayerData.userData.hopae.length == 0 ? '\n(최초 호패는 비용이 들지 않습니다.)' : '\n변경에는 엽전이 소모됩니다.'), {
font: '50pt 궁서',
font: '50pt sejongFont',
color: '#000000',
align: 'center'
}),
......@@ -431,7 +431,6 @@ var gameScene = new Phaser.Class(
sceneKey: 'button'
});
WordSpace.resetGame();
WordSpace.weightTextObjForTest = this.add.text(game.config.width * 5 / 64, game.config.height * 5 / 48, '뇌의 무게: (현재) 0 / ' + this.brainCapacity + ' (전체)').setDepth(9.9).setColor('#000000');
},
create: function()
......@@ -492,27 +491,14 @@ var gameScene = new Phaser.Class(
element.moveObject(element);
});
WordSpace.weightTextObjForTest.setText('뇌의 무게: (현재) '+WordSpace.totalWeight+' / '+ WordSpace.brainCapacity+' (전체)');
WordSpace.setPlayerTyping.add('');
if(!WordSpace.isGameOver)
{
if(WordSpace.totalWeight < 180)
{
this.warningTween.timeScale = 0;
}
else if(WordSpace.totalWeight < 190)
{
this.warningTween.timeScale = 0.3;
}
else if(WordSpace.totalWeight < 200)
{
this.warningTween.timeScale = 0.6;
}
else if(WordSpace.isTimerOn)
{
this.warningTween.timeScale = 0.6 + WordSpace.gameOverCycle.currentCycle.getElapsed() / WordSpace.delay.GameOver * 3;
}
if(WordSpace.totalWeight < 180) this.warningTween.timeScale = 0;
else if(WordSpace.totalWeight < 190) this.warningTween.timeScale = 0.3;
else if(WordSpace.totalWeight < 200) this.warningTween.timeScale = 0.6;
else if(WordSpace.isTimerOn) this.warningTween.timeScale = 0.6 + WordSpace.gameOverCycle.currentCycle.getElapsed() / WordSpace.delay.GameOver * 3;
}
}
}
......
......@@ -10,7 +10,7 @@ UIObject.createLabel = function (scene, x, y, depth, image, size, align, text =
background: scene.add.sprite(x, y, image).setScale(size).setOrigin(0.5, 0.5).setDepth(depth),
text: scene.add.text(x, y, text, {
font: textSize + 'pt 궁서',
font: textSize + 'pt sejongFont',
align: 'center'
}).setDepth(depth).setOrigin(textOriginX, textOriginY).setColor(textColor),
......
......@@ -31,8 +31,7 @@ class WordObject
this.wordObj = scene.add.text(random.x, random.y, this.wordText,
{
fontSize: (this.scale * this.fontScale) +'pt',
fontFamily: '"궁서", 궁서체, serif',
font: (this.scale * this.fontScale) +'pt sejongFont',
//fontStyle: (this.wordWeight > 5 ? 'bold' : '')
});
this.wordObj.setColor(textColor).setOrigin(0.5,0.5).setDepth(1);
......@@ -261,8 +260,7 @@ class NameWord extends WordObject
{
this.physicsObj.setScale(this.follower.t < 0.2 ? 0.2 : this.follower.t * this.scale);
this.wordObj.setFont({
fontSize: (this.follower.t < 0.2 ? 0.05 : this.follower.t * this.scale * this.fontScale) +'pt',
fontFamily: '"궁서", 궁서체, serif',
font: (this.follower.t < 0.2 ? 0.05 : this.follower.t * this.scale * this.fontScale) +'pt sejongFont',
fontStyle: (this.wordWeight > 5 ? 'bold' : '')
});
}
......
var WordSpace = WordSpace || {};
// for test
WordSpace.weightTextObjForTest = null;
WordSpace.nameWordTextForTest = null;
WordSpace.nextWordCode = 0;
......@@ -512,9 +510,6 @@ WordSpace.changePhase = function(newPhase)
}
WordSpace.resetGame = function()
{
WordSpace.weightTextObjForTest = null;
WordSpace.nameWordTextForTest = null;
WordSpace.nextWordCode = 0;
WordSpace.totalWeight = 0; //현재 단어 무게 총합
WordSpace.totalWordNum = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment