Skip to content

Commit e0c17d9

Browse files
authored
Merge pull request #2473 from entrylabs/issue/5764
[#5764] 신규 판단, 값블록 구현 추가 수정
2 parents e63c197 + 5d56afa commit e0c17d9

File tree

6 files changed

+25
-27
lines changed

6 files changed

+25
-27
lines changed

extern/lang/ebs.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1545,7 +1545,7 @@ Lang.Blocks = {
15451545
"CALC_change_string_case_sub_1": "대문자",
15461546
"CALC_change_string_case_sub_2": "소문자",
15471547
"CALC_count_match_string_1": "에서",
1548-
"CALC_count_match_string_2": "의 글자 개수",
1548+
"CALC_count_match_string_2": "의 글자 ",
15491549
"CALC_index_of_string_1": "",
15501550
"CALC_index_of_string_2": "에서",
15511551
"CALC_index_of_string_3": "의 시작 위치",
@@ -1590,7 +1590,6 @@ Lang.Blocks = {
15901590
"entry_bot_name": "엔트리봇",
15911591
"hi_entry": "",
15921592
"hi_entry_en": "",
1593-
"hello_entry": "hello entry",
15941593
"bark_dog": "",
15951594
"walking_entryBot": "엔트리봇_걷기",
15961595
"doggi_bark": "강아지 짖는 소리",
@@ -5467,7 +5466,7 @@ Lang.Helper = {
54675466
"char_at": "입력한 값에서 입력한 숫자 번째의 글자 값입니다. (공백을 포함합니다.)",
54685467
"length_of_string": "입력한 값의 공백을 포함한 글자 수입니다.",
54695468
"substring": "입력한 값에서 입력한 범위 내의 글자 값입니다. (공백을 포함합니다.)",
5470-
"count_match_string": "입력한 값에서 지정한 값의 글자 개수입니다.",
5469+
"count_match_string": "입력한 값에서 지정한 값의 글자 수이며, 영문의 경우 대문자와 소문자를 구분하여 수를 셉니다.",
54715470
"replace_string": "입력한 값에서 지정한 값을 찾아 추가로 입력한 값으로 모두 바꾼 값입니다. (영문 입력 시 대소문자를 구분합니다.)",
54725471
"index_of_string": "입력한 값에서 지정한 값이 처음으로 등장하는 위치 값입니다. (공백을 포함합니다.)",
54735472
"change_string_case": "입력한 영문의 모든 알파벳을 대문자 또는 소문자로 바꾼 값입니다.",

extern/lang/en.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -738,8 +738,8 @@ Lang.Blocks = {
738738
"CALC_change_string_case_3": " ",
739739
"CALC_change_string_case_sub_1": "uppercase",
740740
"CALC_change_string_case_sub_2": "lowercase",
741-
"CALC_count_match_string_1": "'s count of",
742-
"CALC_count_match_string_2": "",
741+
"CALC_count_match_string_1": "count of",
742+
"CALC_count_match_string_2": "in",
743743
"CALC_index_of_string_1": "index of",
744744
"CALC_index_of_string_2": "in",
745745
"CALC_index_of_string_3": "",
@@ -784,7 +784,6 @@ Lang.Blocks = {
784784
"entry_bot_name": "Entrybot",
785785
"hi_entry": "Hello Entry!",
786786
"hi_entry_en": "Hello Entry!",
787-
"hello_entry": "hello entry",
788787
"bark_dog": "dog barking",
789788
"walking_entryBot": "Walking Entrybot",
790789
"doggi_bark": "Doggi's Bark",
@@ -1116,7 +1115,7 @@ Lang.Blocks = {
11161115
"arduino_lite_guide": "• connection guide",
11171116
"JUDGEMENT_is_object_clicked": "Object clicked?",
11181117
"JUDGEMENT_is_type_1": "is",
1119-
"JUDGEMENT_is_type_2": "",
1118+
"JUDGEMENT_is_type_2": "?",
11201119
"is_type_number": "number",
11211120
};
11221121
Lang.video_body_coord_params = {
@@ -4674,7 +4673,7 @@ Lang.Helper = {
46744673
"char_at": "Reports the letter of the input text.",
46754674
"length_of_string": "Reports the length of input text including space.",
46764675
"substring": "Reports the text extracted from the input text between two specified indices. (includes space)",
4677-
"count_match_string": "Reports the number of letters in a specific text in the input text.",
4676+
"count_match_string": "Reports the number of letters in a specific text in the input text case sensitively.",
46784677
"replace_string": "Reports the text that replaced all the input text with another input text. (distinguishes uppercase to lowercase)",
46794678
"index_of_string": "Reports the index of first input text in second input text. (includes space)",
46804679
"change_string_case": "Reports the text that converted to uppercase or lowercase.",
@@ -5258,7 +5257,7 @@ Lang.template = {
52585257
"substring": "%1 %2 %3 %4 %5 %6 %7",
52595258
"replace_string": "%1 %2 %3 %4 %5 %6 %7",
52605259
"change_string_case": "%1 %2 %3 %4 %5",
5261-
"count_match_string": "%3 %2 %1 %4",
5260+
"count_match_string": "%2 %3 %4 %1",
52625261
"index_of_string": "%1 %2 %3 %4 %5",
52635262
"combine_something": "%1 %2 %3 %4 %5",
52645263
"get_sound_volume": "%1 %2",

extern/lang/ko.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1561,7 +1561,7 @@ Lang.Blocks = {
15611561
CALC_change_string_case_sub_1: '대문자',
15621562
CALC_change_string_case_sub_2: '소문자',
15631563
CALC_count_match_string_1: '에서',
1564-
CALC_count_match_string_2: '의 글자 개수',
1564+
CALC_count_match_string_2: '의 글자 ',
15651565
CALC_index_of_string_1: '',
15661566
CALC_index_of_string_2: '에서',
15671567
CALC_index_of_string_3: '의 시작 위치',
@@ -1606,7 +1606,6 @@ Lang.Blocks = {
16061606
entry_bot_name: '엔트리봇',
16071607
hi_entry: '안녕 엔트리!',
16081608
hi_entry_en: 'Hello Entry!',
1609-
hello_entry: 'hello entry',
16101609
bark_dog: '강아지 짖는 소리',
16111610
walking_entryBot: '엔트리봇_걷기',
16121611
doggi_bark: '강아지 짖는 소리',
@@ -6030,7 +6029,7 @@ Lang.Helper = {
60306029
char_at: '입력한 값에서 입력한 숫자 번째의 글자 값입니다. (공백을 포함합니다.)',
60316030
length_of_string: '입력한 값의 공백을 포함한 글자 수입니다.',
60326031
substring: '입력한 값에서 입력한 범위 내의 글자 값입니다. (공백을 포함합니다.)',
6033-
count_match_string: '입력한 값에서 지정한 값의 글자 개수입니다.',
6032+
count_match_string: '입력한 값에서 지정한 값의 글자 수이며, 영문의 경우 대문자와 소문자를 구분하여 수를 셉니다.',
60346033
replace_string:
60356034
'입력한 값에서 지정한 값을 찾아 추가로 입력한 값으로 모두 바꾼 값입니다. (영문 입력 시 대소문자를 구분합니다.)',
60366035
index_of_string:

extern/util/static.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,10 +347,10 @@ EntryStatic.getAllBlocks = function() {
347347
'get_user_name',
348348
'get_nickname',
349349
'length_of_string',
350+
'count_match_string',
350351
'combine_something',
351352
'char_at',
352353
'substring',
353-
'count_match_string',
354354
'index_of_string',
355355
'replace_string',
356356
'reverse_of_string',

src/playground/blocks/block_calc.js

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1100,14 +1100,14 @@ module.exports = {
11001100
],
11011101
events: {
11021102
viewAdd: [
1103-
function () {
1103+
function() {
11041104
if (Entry.engine) {
11051105
Entry.engine.showProjectTimer();
11061106
}
11071107
},
11081108
],
11091109
viewDestroy: [
1110-
function (block, notIncludeSelf) {
1110+
function(block, notIncludeSelf) {
11111111
if (Entry.engine) {
11121112
Entry.engine.hideProjectTimer(block, notIncludeSelf);
11131113
}
@@ -1176,7 +1176,7 @@ module.exports = {
11761176
},
11771177
],
11781178
dataDestroy: [
1179-
function (block) {
1179+
function(block) {
11801180
if (Entry.engine) {
11811181
Entry.engine.hideProjectTimer(block);
11821182
}
@@ -1307,14 +1307,14 @@ module.exports = {
13071307
],
13081308
events: {
13091309
viewAdd: [
1310-
function () {
1310+
function() {
13111311
if (Entry.engine) {
13121312
Entry.engine.showProjectTimer();
13131313
}
13141314
},
13151315
],
13161316
viewDestroy: [
1317-
function (block, notIncludeSelf) {
1317+
function(block, notIncludeSelf) {
13181318
if (Entry.engine) {
13191319
Entry.engine.hideProjectTimer(block, notIncludeSelf);
13201320
}
@@ -1396,10 +1396,10 @@ module.exports = {
13961396
[Lang.Blocks.CALC_get_date_year, 'YEAR'],
13971397
[Lang.Blocks.CALC_get_date_month, 'MONTH'],
13981398
[Lang.Blocks.CALC_get_date_day, 'DAY'],
1399+
[Lang.Blocks.CALC_get_date_day_of_week, 'DAY_OF_WEEK'],
13991400
[Lang.Blocks.CALC_get_date_hour, 'HOUR'],
14001401
[Lang.Blocks.CALC_get_date_minute, 'MINUTE'],
14011402
[Lang.Blocks.CALC_get_date_second, 'SECOND'],
1402-
[Lang.Blocks.CALC_get_date_day_of_week, 'DAY_OF_WEEK'],
14031403
],
14041404
value: 'YEAR',
14051405
fontSize: 10,
@@ -1522,13 +1522,13 @@ module.exports = {
15221522
const mousePos = Entry.stage.mouseCoordinate;
15231523
return Math.sqrt(
15241524
Math.pow(sprite.getX() - mousePos.x, 2) +
1525-
Math.pow(sprite.getY() - mousePos.y, 2)
1525+
Math.pow(sprite.getY() - mousePos.y, 2)
15261526
);
15271527
} else {
15281528
const targetEntity = Entry.container.getEntity(targetId);
15291529
return Math.sqrt(
15301530
Math.pow(sprite.getX() - targetEntity.getX(), 2) +
1531-
Math.pow(sprite.getY() - targetEntity.getY(), 2)
1531+
Math.pow(sprite.getY() - targetEntity.getY(), 2)
15321532
);
15331533
}
15341534
},
@@ -1781,7 +1781,10 @@ module.exports = {
17811781
isNotFor: ['python_disable'],
17821782
func(sprite, script) {
17831783
const originStr = script.getStringValue('STRING', script);
1784-
const reversedStr = originStr.split('').reverse().join('');
1784+
const reversedStr = originStr
1785+
.split('')
1786+
.reverse()
1787+
.join('');
17851788
return reversedStr;
17861789
},
17871790
syntax: {
@@ -2154,7 +2157,7 @@ module.exports = {
21542157
params: [
21552158
{
21562159
type: 'text',
2157-
params: [Lang.Blocks.hello_entry],
2160+
params: [Lang.Blocks.hi_entry_en],
21582161
},
21592162
null,
21602163
{
@@ -2457,7 +2460,7 @@ module.exports = {
24572460
func(sprite, script) {
24582461
return script
24592462
.getStringValue('STRING', script)
2460-
[script.getField('CASE', script)]();
2463+
[script.getField('CASE', script)]();
24612464
},
24622465
syntax: {
24632466
js: [],

src/playground/blocks/block_judgement.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -274,9 +274,7 @@ module.exports = {
274274
},
275275
{
276276
type: 'Dropdown',
277-
options: [
278-
[Lang.Blocks.is_type_number, 'number'],
279-
],
277+
options: [[Lang.Blocks.is_type_number, 'number']],
280278
value: 'number',
281279
fontSize: 10,
282280
bgColor: EntryStatic.colorSet.block.darken.JUDGE,

0 commit comments

Comments
 (0)