Compare commits

..

5 Commits

Author SHA1 Message Date
Pavel Shevaev d3678bb8b9 Migrating to more robust bhl_custom_rw semantics 2024-12-28 15:21:11 +03:00
Pavel Shevaev 64d00bee4c Обновить CHANGELOG.md 2024-12-19 10:56:05 +03:00
Pavel Shevaev 294faf5faf Merge branch 'master' of https://git.bit5.ru/bit/metagen_bhl_bind_ecslite 2024-12-05 19:43:31 +03:00
Pavel Shevaev 7e75c1aba0 Trying make more flexible deps 2024-12-05 19:42:59 +03:00
Pavel Shevaev 8ad4b6c460 Обновить CHANGELOG.md 2024-11-21 14:37:12 +03:00
3 changed files with 11 additions and 7 deletions

View File

@ -1,2 +1,8 @@
## v2.6.0
- More flexible composer dependencies
## v2.5.0
- Using local static functions instead of lambdas for better stack traces
## v2.0.0
- Bumping dependency from bit/metagen_bhl_bind up to v13.0.0

View File

@ -4,9 +4,9 @@
"homepage": "https://git.bit5.ru/bit/metagen_bhl_bind_ecslite",
"require": {
"php": ">=7.4",
"twig/twig" : "v3.4.3",
"bit/metagen" : "^v3.0.0",
"bit/metagen_bhl_bind" : "^v13.0.0 || ^v14.0.0 || ^15.0.0"
"twig/twig" : "^v3.4.3",
"bit/metagen" : ">=v3.0.0",
"bit/metagen_bhl_bind" : ">=v13.0.0"
},
"autoload": {
"files": [

View File

@ -57,15 +57,13 @@ class BindEclLitePlugin implements \bhl_bind\BindPlugin
$code .= "#if !BHL_FRONT\n";
$code .= "public static bool TryUnpackEcsEntity(ValStack stack, out EcsWorld world, out int id)\n";
$code .= "{\n";
$code .= " EcsPackedEntityWithWorld e = default;\n";
$code .= " stack.PopRelease().Decode(ref e);\n\n";
$code .= " var e = stack.PopRelease().Decode(new EcsPackedEntityWithWorld());\n\n";
$code .= " return e.Unpack(out world, out id);\n";
$code .= "}\n\n";
$code .= "public static void UnpackEcsEntity(ValStack stack, out EcsWorld world, out int id)\n";
$code .= "{\n";
$code .= " EcsPackedEntityWithWorld e = default;\n";
$code .= " stack.PopRelease().Decode(ref e);\n\n";
$code .= " var e = stack.PopRelease().Decode(new EcsPackedEntityWithWorld());\n\n";
$code .= " if(e.Unpack(out world, out id) == false)\n";
$code .= " throw new Exception(\"No entity found\");\n";
$code .= "}\n\n";