Skip to content

Commit 4152450

Browse files
committed
Patch-A
1 parent 864c5d2 commit 4152450

File tree

39 files changed

+1446
-1056
lines changed

39 files changed

+1446
-1056
lines changed

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
def javaVersion = '1.7';
2-
def projectVersion = '0.8.0';
2+
def projectVersion = '0.9.0';
33
def jphpVersion = projectVersion + "-SNAPSHOT";
44

55
rootProject.ext.jphpVersion = jphpVersion;

develnext/launcher/DevelNext.exe

0 Bytes
Binary file not shown.

develnext/launcher/winLauncher.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030

3131
<opt>-Dfile.encoding=UTF-8</opt>
3232
<opt>-Ddevelnext.launcher=root</opt>
33+
<opt>-Dprism.verbose=true</opt>
3334
</jre>
3435
<versionInfo>
3536
<fileVersion>4.0.0.0</fileVersion>

develnext/misc/history.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
Patch-A
2+
------------
3+
- Исправлен баг события клавиатура, под-событие "любая буква" не работало.
4+
15
Beta-1
26
------------
37
+ Реализована новая удобная система управления проектом через вкладку "Проект".

develnext/src/.dn/behaviours

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,4 @@ ide\behaviour\spec\GameEntityBehaviourSpec
2626
ide\behaviour\spec\GridMovementBehaviourSpec
2727
ide\behaviour\spec\WrapScreenBehaviourSpec
2828
ide\behaviour\spec\LimitedMovementBehaviourSpec
29+
ide\behaviour\spec\CameraTargetBehaviourSpec

develnext/src/ide/behaviour/spec/AbstractEffectBehaviourSpec.php

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use php\gui\framework\behaviour\custom\AbstractBehaviour;
1515
use php\gui\framework\behaviour\custom\EffectBehaviour;
1616
use php\gui\UXNode;
17+
use php\lang\IllegalStateException;
1718
use php\lib\arr;
1819
use php\lib\reflect;
1920

@@ -55,17 +56,21 @@ public function refreshNode(UXNode $node, AbstractBehaviour $behaviour)
5556
public function deleteSelf(UXNode $node, AbstractBehaviour $behaviour)
5657
{
5758
if ($behaviour instanceof EffectBehaviour) {
58-
$removed = [];
59-
$testEffect = $behaviour->makeEffect();
59+
try {
60+
$removed = [];
61+
$testEffect = $behaviour->makeEffect();
6062

61-
foreach ($node->effects as $effect) {
62-
if (get_class($effect) == get_class($testEffect)) {
63-
$removed[] = $effect;
63+
foreach ($node->effects as $effect) {
64+
if (get_class($effect) == get_class($testEffect)) {
65+
$removed[] = $effect;
66+
}
6467
}
65-
}
6668

67-
foreach ($removed as $one) {
68-
$node->effects->remove($one);
69+
foreach ($removed as $one) {
70+
$node->effects->remove($one);
71+
}
72+
} catch (IllegalStateException $e) {
73+
throw new IllegalStateException("Unable delete " . reflect::typeOf($behaviour) . ", message = {$e->getMessage()}");
6974
}
7075
}
7176
}
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
<?php
2+
namespace ide\behaviour\spec;
3+
4+
use behaviour\custom\BlinkAnimationBehaviour;
5+
use behaviour\custom\CameraTargetBehaviour;
6+
use behaviour\custom\ChatterAnimationBehaviour;
7+
use behaviour\custom\DraggingBehaviour;
8+
use behaviour\custom\DraggingFormBehaviour;
9+
use behaviour\custom\GameEntityBehaviour;
10+
use behaviour\custom\GameSceneBehaviour;
11+
use behaviour\custom\LimitedMovementBehaviour;
12+
use behaviour\custom\WrapScreenBehaviour;
13+
use ide\behaviour\AbstractBehaviourSpec;
14+
use ide\formats\form\AbstractFormElement;
15+
use ide\formats\form\elements\FormFormElement;
16+
use ide\formats\form\elements\GamePaneFormElement;
17+
use ide\formats\form\elements\PanelFormElement;
18+
use ide\formats\form\elements\ScrollPaneFormElement;
19+
use ide\formats\form\elements\SpriteViewFormElement;
20+
use ide\scripts\AbstractScriptComponent;
21+
use php\gui\UXNode;
22+
23+
class CameraTargetBehaviourSpec extends AbstractBehaviourSpec
24+
{
25+
/**
26+
* @return string
27+
*/
28+
public function getName()
29+
{
30+
return 'Цель камеры';
31+
}
32+
33+
public function getGroup()
34+
{
35+
return self::GROUP_GAME;
36+
}
37+
38+
public function getIcon()
39+
{
40+
return "icons/gameMonitor16.png";
41+
}
42+
43+
/**
44+
* @return string
45+
*/
46+
public function getDescription()
47+
{
48+
return 'За объектом будет следовать вся сцена, словно за ним следит камера.';
49+
}
50+
51+
/**
52+
* @return string
53+
*/
54+
public function getType()
55+
{
56+
return CameraTargetBehaviour::class;
57+
}
58+
59+
/**
60+
* @param $target
61+
* @return bool
62+
*/
63+
public function isAllowedFor($target)
64+
{
65+
return !($target instanceof AbstractScriptComponent)
66+
&& !($target instanceof FormFormElement);
67+
}
68+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<behaviour extends="BehaviourSpec">
2+
<properties>
3+
<property code="position" name="Позиционирование" editor="enum" tooltip="Позиционирование камеры относительно целевого объекта">
4+
<variants>
5+
<variant value="CENTER">Центрированное</variant>
6+
<variant value="RELATIVE">Относительное</variant>
7+
</variants>
8+
</property>
9+
</properties>
10+
</behaviour>

develnext/src/ide/behaviour/spec/FadeAnimationBehaviourSpec.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ class FadeAnimationBehaviourSpec extends AbstractBehaviourSpec
2020
*/
2121
public function getName()
2222
{
23-
return 'Прозрачность (fade)';
23+
return 'Затухание';
2424
}
2525

2626
public function getGroup()

develnext/src/ide/editors/ProjectEditor.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ public function __construct($file)
6262

6363
if ($pane instanceof AbstractProjectControlPane) {
6464
$this->controlPanes[$one] = $pane;
65+
$pane->on('updateCount', function () {
66+
$this->menu->refresh();
67+
});
6568
} else {
6669
Logger::error("Unable to register $one control pane, class is not instance of AbstractProjectControlPane");
6770
}

0 commit comments

Comments
 (0)