Search Unity

  1. Unity 2019.2 is now released.
    Dismiss Notice

Project Tiny C# Preview (0.15.3) available

Discussion in 'Project Tiny' started by JC-Cimetiere, Jun 3, 2019.

Thread Status:
Not open for further replies.
  1. ovirta

    ovirta

    Joined:
    Mar 20, 2015
    Posts:
    36
    Appreciate your response but unfortunately that is not the case. This is an older laptop with two display adapters. Been having issues not related to Unity from time to time with them. Thought I would bring this up as I am having no issues with "normal" unity projects.

    Will update the display drivers and will let you know what happens. Thanks!
     
  2. badiba

    badiba

    Joined:
    Apr 9, 2018
    Posts:
    8
    I'm having trouble with NativeList. Apparently it's okay to get the last added element from a NativeList but not the former ones. For example I keep trying to get the first element from the NativeList while I keep adding new ones. And I get this error:

    Code (CSharp):
    1. Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
    2.    at System.Buffer.__Memmove(Byte* dest, Byte* src, UInt32 len)
    3.    at System.Buffer._Memmove(Byte* dest, Byte* src, UInt32 len)
    4.    at System.Buffer.Memmove(Byte* dest, Byte* src, UInt32 len)
    5.    at System.String.CopyTo(Int32 sourceIndex, Char[] destination, Int32 destinationIndex, Int32 count)
    6.    at System.IO.TextWriter.WriteLine(String value)
    7.    at System.IO.TextWriter.SyncTextWriter.WriteLine(String value)
    8.    at System.Console.WriteLine(String value)
    9.    at Otsimo.LoggingSystem.LogInfo() in C:\Unity\tinygit\Assets\Story\Scripts\Utils\LoggingSystem.cs:line 133
    10.    at Otsimo.LoggingSystem.OnUpdate() in C:\Unity\tinygit\Assets\Story\Scripts\Utils\LoggingSystem.cs:line 55
    11.    at Unity.Entities.ComponentSystem.InternalUpdate() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\ComponentSystem.cs:line 818
    12.    at Unity.Entities.ComponentSystemBase.Update() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\ComponentSystem.cs:line 287
    13.    at Unity.Entities.ComponentSystemGroup.OnUpdate() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\ComponentSystemGroup.cs:line 451
    14.    at Unity.Entities.ComponentSystem.InternalUpdate() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\ComponentSystem.cs:line 818
    15.    at Unity.Entities.ComponentSystemBase.Update() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\ComponentSystem.cs:line 287
    16.    at Unity.Entities.World.Update() in C:\Unity\tinygit\Library\PackageCache\com.unity.entities@0.0.12-preview.33\Unity.Entities\World.cs:line 386
    17.    at Unity.Tiny.EntryPoint.Program.MainLoop() in C:\Unity\tinygit\Library\PackageCache\com.unity.tiny@0.15.3-preview\DotsModules\Unity.Tiny.EntryPoint\Main.cs:line 58
    18.    at Unity.Tiny.GLFW.GLFWWindowSystem.InfiniteMainLoop(MainLoopDelegate m) in C:\Unity\tinygit\Library\PackageCache\com.unity.tiny@0.15.3-preview\DotsModules\Unity.Tiny.GLFW\GLFW.cs:line 27
    19.    at Unity.Tiny.EntryPoint.Program.Main() in C:\Unity\tinygit\Library\PackageCache\com.unity.tiny@0.15.3-preview\DotsModules\Unity.Tiny.EntryPoint\Main.cs:line 43
     
  3. ColdFire_JimRaid

    ColdFire_JimRaid

    Joined:
    Jun 11, 2019
    Posts:
    1
    We already built a playable ad with Project Tiny C# but we have trouble repackaging it into a single html file. Could you provide us with a small guide how to do that if it is even possible right now?

    Can we expect the "Playable Ads" build target in the near future?
     
  4. ovirta

    ovirta

    Joined:
    Mar 20, 2015
    Posts:
    36
    Unfortunately updating display drivers to latest did not help.
     
  5. zhuchun

    zhuchun

    Joined:
    Aug 11, 2012
    Posts:
    385
    Thanks for bringing this, you guys rock! ;)
     
  6. ovirta

    ovirta

    Joined:
    Mar 20, 2015
    Posts:
    36
    Got my hands on another laptop T440s and dotnet build runs fine there. This more or less fixes my problems but of course it would be nice to be able use the old machine for these builds too. No need to put task on top of your bucket list though ;)

    Thanks and keep on improving already excellent project!
     
  7. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,517
    We will eventually make Windows builds use DirectX (in the far future), so this will be non issue. OpenGL is just a mess :/.
     
    Manny_bit and ovirta like this.
  8. vincismurf

    vincismurf

    Joined:
    Feb 28, 2013
    Posts:
    188
    Failed on Beta 6 sigh

    Code (csharp):
    1.  
    2. Build failed. Open D:\YOU\2dtemplate\Library\DotsRuntimeBuild\build.log for more details.
    3. [     0s] Build frontend of artifacts\buildprogram\buildprogram_buildprogram.dag ran (no suitable previous build dag file)
    4. [1/5  0s] CSProject buildprogram-build.gen.csproj
    5. [2/5  0s] Download and unpack artifacts/buildprogrambuildprogram/Stevedore/7za-win-x64/.StevedoreVersion (+1 other)
    6. [3/5  1s] Download and unpack artifacts/buildprogrambuildprogram/Stevedore/roslyn-csc-win64/.StevedoreVersion (+1 other)
    7. [4/5  1s] Csc artifacts/buildprogram/buildprogram_buildprogram.exe (+2 others)
    8. [     4s] Build frontend of artifacts\buildprogram\tundra_buildprogram.dag ran (no suitable previous build dag file)
    9. [ 1/13  0s] WriteResponseFile artifacts/rsp/1008532451738831585.rsp
    10. [ 2/13  0s] WriteResponseFile artifacts/rsp/16678227308262555357.rsp
    11. [ 3/13  0s] CSProject D:/YOU/2dtemplate/Library/PackageCache/com.unity.tiny@0.15.3-preview/DotsPlayer/bee~/BuildProgramBuildProgramSources/buildprogrambuildprogram.gen.csproj
    12. [ 4/13  0s] CSProject D:/YOU/2dtemplate/Library/DotsRuntimeBuild/buildprogram.gen.csproj
    13. [ 5/13  0s] VisualStudioSolution build.gen.sln
    14. [ 6/13  0s] CopyTool artifacts/buildprogrambuildprogram.exe/Release/bee.exe
    15. [ 7/13  0s] CopyTool artifacts/buildprogram/bee.exe
    16. [ 8/13  0s] Download and unpack artifacts/Stevedore/7za-win-x64/.StevedoreVersion (+1 other)
    17. [ 9/13  0s] Download and unpack artifacts/Stevedore/referenceassemblies_v471/.StevedoreVersion (+1 other)
    18. [10/13  2s] Download and unpack artifacts/Stevedore/roslyn-csc-win64/.StevedoreVersion (+1 other)
    19. [11/13  1s] Csc artifacts/buildprogrambuildprogram.exe/Release/buildprogrambuildprogram.exe (+2 others)
    20. [12/13  1s] Csc artifacts/buildprogram/buildprogram.exe (+2 others)
    21. error: Error reading JObject from JsonReader. Path '', line 1, position 390. (Newtonsoft.Json.JsonReaderException)
    22.   at Newtonsoft.Json.Linq.JObject.Load
    23.   at Newtonsoft.Json.Linq.JObject.Parse
    24.   at Bee.Stevedore.Program.FileList.ParseFromString
    25.   at Bee.Stevedore.Program.FileList.ParseFromString
    26.   at Bee.Stevedore.StevedoreArtifact.GetFileList
    27.   at EditorToolsBuildProgram.SetupGetEditorToolsFromStevedore in D:/YOU/2dtemplate/Library/PackageCache/com.unity.tiny@0.15.3-preview/DotsPlayer/bee~/BuildProgramSources/EditorToolsBuildProgram.cs(144)
    28.   at BuildProgram.Main in D:/YOU/2dtemplate/Library/PackageCache/com.unity.tiny@0.15.3-preview/DotsPlayer/bee~/BuildProgramSources/BuildProgram.bee.cs(118)
    29. *** Tundra build failed to setup error (10.53 seconds), 0 items updated
    30. [E] DAG generator driver failed: "D:\YOU\2dtemplate\Library\PackageCache\com.unity.tiny@0.15.3-preview\DotsPlayer\bee~\bee.exe" build --beemode=ToCreateBuildGraph --root-artifacts-path=artifacts --bee-driver-buildprogramroot=.
    31.  
    32. UnityEngine.Debug:LogError(Object)
    33. Unity.Debug:LogError(Object) (at Library/PackageCache/com.unity.entities@0.0.12-preview.33/Unity.Entities/Stubs/Unity/Debug.cs:10)
    34. Unity.Editor.Build.BuildStepRunBee:Run(BuildContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildStepRunBee.cs:83)
    35. Unity.Editor.Build.BuildPipeline:RunBuildSteps(IReadOnlyList`1, BuildContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildPipeline.cs:137)
    36. Unity.Editor.Build.BuildPipeline:Build(BuildSettings) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildPipeline.cs:110)
    37. Unity.Editor.Application:Build() (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Application.cs:131)
    38. Unity.Editor.Application:BuildAndRun() (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Application.cs:142)
    39. Unity.Editor.Modes.PlayBar:PlayCommandHandler(CommandExecuteContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/PlayBar.cs:15)
    40. UnityEditor.CommandService:Execute(String)
    41. Unity.Editor.Modes.PlayBar:DrawPlayBar(CommandExecuteContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/PlayBar.cs:79)
    42. UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
    43.  
    44.  
     
  9. mivey_unity

    mivey_unity

    Joined:
    Jun 18, 2019
    Posts:
    4
    Got it working after a couple attempts.

    1. It seems like there's a race condition when creating a new project where if I open the DOTS project too soon, sometimes gives errors like "NullReferenceException: Object reference not set to an instance of an object Unity.Authoring.ChangeTracking.ChangeManager.Update()". I'm having trouble reproducing this right now though.

    2. Sometimes when coming back from changing a script in Visual Studio, Unity closes the DOTS project. The area with the "macOS dotnet | Debug | Play" buttons switches to an "Open a DOTS project" button. I have to go back through the DOTS > Open Project... menu to get my play button back.

    3. Does the "Open a DOTS project" button ever work? Any time I click it, it gives the error "ArgumentException: Command DOTS/Open Project... does not exist". The DOTS > Open Project... menu does work for me.

    Unity 2019.2.0b6
    OSX 10.14.5
    Tiny 0.15.3
     
  10. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    Unable to build to Net or IL2CPP keep getting file errors, asm and wasm builds work?
     
  11. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    What are the errors you're getting?
     
  12. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    OK I have Visual Studio 2019 and it does not have /bin/Hostx86/x86/cl.exe so how do I point this back the MS VS 2017 or update 2019 to have this?
     
    sw_DreamAD likes this.
  13. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    Fixed installed C++ desktop app development to MS Visual Studio 2019.

    Why doesn't Tiny test for the build environment it needs then displays errors/warnings and limits build options or at least give more meaningful errors?
     
  14. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    Wow wait a minute the tiny dot net release build folder for Joystick is 102 Mb?

    And it has over 100 files most of which are .dll and .pdb which look like they are debug style files do I need to change some settings other than the Build Target and Release Type drop downs?

    It looks like 101 Mb of the 102 Mb is the .pdb files which are Type Program Debug Database each weighing in at > 4Mb.

    How do I prevent the Release build process from generating these files?
     
    Last edited: Jun 21, 2019
  15. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    Is the build pipeline stage for the different targets similar?
    • DOTNET
    • IL2CPP
    • ASM
    • WASM
    For instance if build target 1 uses stages A B C and target 2 uses A B C D then why not have common build stages (ABC) in a common build process, in theory this could greatly speed up build times when only the build target is changed in development.
     
  16. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,517
    You don't want to prevent the build process to generate those files, otherwise you won't be able to debug the code or crash dumps.
     
    Manny_bit likes this.
  17. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    I can understand that in the Debug and Development builds but not a Release build.
     
  18. Tautvydas-Zilys

    Tautvydas-Zilys

    Unity Technologies

    Joined:
    Jul 25, 2013
    Posts:
    6,517
    You might get crashes in the wild at some point. If we were to delete debugging symbols, you'd have no way of debugging crash dumps.
     
  19. Vecna

    Vecna

    Joined:
    Apr 2, 2014
    Posts:
    23
    I'm getting this error when trying to build to both web platforms.

    Code (CSharp):
    1. Build failed. Open C:\UnityProjects\Tinyj\Library\DotsRuntimeBuild\build.log for more details.
    2. ##### ExitCode
    3. 1
    4. ##### Output
    5. shared:ERROR: 'C:\UnityProjects\Tinyj\Library\DotsRuntimeBuild\artifacts\Stevedore\emscripten-llvm-win-x64\emscripten-llvm-e1.38.28-2019_04_05_07_52\clang++.exe --version' failed: [Error 6] The handle is invalid
    6. *** Bee build failed (5.77 seconds), 21 items updated
    7.  
    8.  
     
  20. sercand

    sercand

    Joined:
    Nov 7, 2013
    Posts:
    6
    Is there any way to build a project with the command line for CI/CD use?
    "Unity.Editor.Project" constructor seems private so I can't construct and call ".Build" method.
     
  21. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    So do I only need them on my 'developers release' build or do I need them on the client version as well?
     
  22. JJJohan

    JJJohan

    Joined:
    Mar 18, 2016
    Posts:
    206
    You wouldn't necessarily release the PDBs to the client, but you would keep them so you can debug an issue that the client reports, this way you can trace a crash down to a useful stack trace via the symbol files.
     
    Arowx likes this.
  23. qoly

    qoly

    Joined:
    Jun 18, 2019
    Posts:
    7
    How to use UnityEngine.Networking in Project Tiny C#? If i wrote
    using UnityEngine.Networking;
    than build failed.
     
  24. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    The reason that Tiny is tiny is that it excludes the existing classic Unity SDK and replaces it with a new, smaller one. If you want to see what functionality is available to you, you can browse through the package's source code in the PackageCache folder.
     
  25. qoly

    qoly

    Joined:
    Jun 18, 2019
    Posts:
    7
    So how can i load any files from server in runtime? Or it impossible in Tiny?
     
    Last edited: Jun 25, 2019
  26. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    The function Unity.Tiny.IO.IOService.RequestAsyncRead() may help you. You can do a find-in-files in the packages folder to see how it's implemented and how it's used elsewhere.
     
  27. qoly

    qoly

    Joined:
    Jun 18, 2019
    Posts:
    7
    AsyncOp.GetData() returns nothing. Just out some byte* and int. What's it and how this byte* convert to my data files like images, texts and other?

    Code (CSharp):
    1. using Unity.Entities;
    2. using Unity.Tiny.IO;
    3. using Unity.Tiny.Debugging;
    4.  
    5. public class LoaderSystem : ComponentSystem
    6. {
    7.     AsyncOp ao;
    8.     protected override void OnCreate()
    9.     {
    10.         ao = IOService.RequestAsyncRead("D:/UnityProjects/MyTinyProject/Assets/MyDOTSProject/Resources/Images/image.png");
    11.         Debug.Log("Error is " + ao.GetErrorStatus().ToString());
    12.     }
    13.     protected override void OnUpdate()
    14.     {
    15.         if (ao.IsCreated && ao.GetStatus() == AsyncOp.Status.Success)
    16.         {
    17.             unsafe
    18.             {
    19.                 byte* data;
    20.                 int size;
    21.                 ao.GetData(out data, out size);
    22.                 Debug.Log("Size is " + size.ToString());
    23.                 ao.Dispose();
    24.             }
    25.         }
    26.     }
    27. }
     
  28. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    The byte* data is a pointer to the area in memory which contains the data that was read from the file.
    See https://www.c-sharpcorner.com/article/pointers-in-C-Sharp/ for more on that.

    You'd then need to pass that data into other functions (which you'd either find on the web, in the existing Tiny source code, or write yourself) to be parsed.

    If it's images in particular you're after, there's an easier way; see `Unity.Tiny.Utils.DemoUtils.CreateImage2D()`. That will return an entity with an `Image2D` component and start loading it in the background. You can find out when it's done loading by checking the field `Image2D.status`. You can pass that image entity to `DemoUtils.CreateSprite()` and that returned sprite entity to `DemoUtils.CreateRenderer()`. Please note that I have no idea if the functions in `DemoUtils` actually work; I'm not seeing them used anywhere else in the project. But their implementations should at least give you an idea of how you'd go about loading and rendering images at runtime. (See the child classes of `Unity.Tiny.Core2D.GenericAssetLoader` if you're curious about the systems that actually operate on the components added by the functions in `DemoUtils` to load and parse the image files.)
     
  29. Rocco_B

    Rocco_B

    Joined:
    Oct 28, 2016
    Posts:
    25
    We are closing in on one month since the C# release (July 3rd). I am in no particular rush but just curious if there is some sort of timeline of when the next update to Project Tiny may drop and what it may contain?
     
    Ferran_SP likes this.
  30. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    By the way -- to the people on Unity working on this stuff -- I want to take a break from reporting bugs and asking questions and asking for updates to say thank you. C# Tiny/DOTS Runtime is wonderful, and everything I hoped it would be (considering the early stage). Maybe more.
     
    Maras, zhuchun, Rocco_B and 2 others like this.
  31. oceanxiao

    oceanxiao

    Joined:
    Jan 19, 2016
    Posts:
    10
    Hi, I have some problem with building samples, can any one help? thx~
    upload_2019-6-28_18-0-58.png
    upload_2019-6-28_18-1-23.png

    Build failed. Open D:\NewUnityProject\Library\DotsRuntimeBuild\build.log for more details.
    ##### ExitCode
    1
    ##### Output
    shared:ERROR: 'D:\NewUnityProject\Library\DotsRuntimeBuild\artifacts\Stevedore\emscripten-llvm-win-x64\emscripten-llvm-e1.38.28-2019_04_05_07_52\clang++.exe --version' failed: [Error 6]
    *** Bee build failed (0.76 seconds), 11 items updated
    UnityEngine.Debug:LogError(Object)
    Unity.Debug:LogError(Object) (at Library/PackageCache/com.unity.entities@0.0.12-preview.33/Unity.Entities/Stubs/Unity/Debug.cs:10)
    Unity.Editor.Build.BuildStepRunBee:Run(BuildContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildStepRunBee.cs:83)
    Unity.Editor.Build.BuildPipeline:RunBuildSteps(IReadOnlyList`1, BuildContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildPipeline.cs:137)
    Unity.Editor.Build.BuildPipeline:Build(BuildSettings) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Build/BuildPipeline.cs:110)
    Unity.Editor.Application:Build() (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Application.cs:131)
    Unity.Editor.Application:BuildAndRun() (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor/Application.cs:142)
    Unity.Editor.Modes.PlayBar:playCommandHandler(CommandExecuteContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/PlayBar.cs:15)
    UnityEditor.CommandService:Execute(String)
    Unity.Editor.Modes.PlayBar:DrawPlayBar(CommandExecuteContext) (at Library/PackageCache/com.unity.tiny@0.15.3-preview/Unity.Editor/Unity.Editor.Modes/PlayBar.cs:79)
    UnityEngine.GUIUtility:processEvent(Int32, IntPtr)
     
  32. oceanxiao

    oceanxiao

    Joined:
    Jan 19, 2016
    Posts:
    10
    Another question. I wrote this code:
    float x = -0.740f;
    Debug.LogFormat("test {0}", x);
    When in chrome Devtools console, it outputs: test 0.740
     
  33. winxalex

    winxalex

    Joined:
    Jun 29, 2014
    Posts:
    131

    Thx for the book I'll def read. But notice that is bit much theoretical. I like to learn on simple practical examples even in pseudo code.

    OK. You are right!. Systems can communicate. Why they don't?
    Do you think that:
    1. this.world.usingCompentData(explosion,TransformLocalPosition)(is this doing query???)
    2. explosion.GetComponent<TransformLocalPosition>
    is best way of doing this. Code look the same as with MonoBehaviour, you do, OnCollision( and inside you instantiate prefab(explosion) and access prefab then do GetComponent<Transform> and add transform.position=position. Which I consider as hardcode design.

    Seems to me, that PlayerCollisionSystem is not communicating with ExplossionSystem(not such system existing at all), but hard code grab control of ExplossionSystem(if existed, should exist???).
    What Collision System should do, is to check hit(here event happen want it or not) and notify by create new entity with event component, with type, data like position of hit or whatever. ExplossionSystem should query in update for such entity containing event component, and if exist, take data, instantiate new explosion entity at position...

    If we replace the alphabet handling code with condition tables, then we can produce output tables of transitions to commit. If each state is represented by a condition table, and any entity in that state represented by a row in a state table, then we can run each state in turn, collecting any transitions in buffers, then committing these changes after everything has finished a single update step.
     
  34. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    That "no input files" error is pretty surprising-looking. All you did was import that Tiny sample project into your Unity project, open it, select the platform and build configration, and press play? No changes to the sample's content or configuration? If so, you may need to file a bug report.
     
  35. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    That *definitely* sounds like a bug worth reporting. :) But if you're not able to build, how did you get as far as testing Tiny code in the browser at all?
     
  36. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    I'm not really familiar with the API of the older, TypeScript-based Tiny that the example you shared uses; I only jumped on board when the C# version came out. But it looks like that code is behaving pretty similarly to the GameObject/MonoBehaviour approach you described, which I agree is not the ideal way to implement this behavior in an ECS archtecture (except, perhaps, in a toy-like context to teach new users the API).

    Agreed!

    Maybe!

    That would also be a hardcoded-design, right? The explosion system would probably be duplicating a "prefab" explosion entity. (As in this example.) What if that prefab explosion entity didn't already have a component storing the entity's position?

    In theory, you would want one system to spawn the explosion entity and add a request-set-position component to it and then another system to run which does something like --

    Code (csharp):
    1. For Each entity which is an explosion and has a position component and has a request-set-position component:
    2. - Set the position component to that which is specified by the request-set-position component
    3. - Remove the request-set-position component from the entity.
    But that extra indirection might be a bit excessive, depending on the architecture of the project. I think it's reasonable at a certain point for code (especially data-oriented code) to trust that the data with which it's being provided is of a certain format. (And you can add assertations to validate those assumptions in non-release builds.) You wouldn't expect a PNG importer to behave properly if you gave it a JPEG, after all.
     
    Last edited: Jul 1, 2019
  37. oceanxiao

    oceanxiao

    Joined:
    Jan 19, 2016
    Posts:
    10
    hi, because I install Unity on another computer and build my tiny project.
     
  38. oceanxiao

    oceanxiao

    Joined:
    Jan 19, 2016
    Posts:
    10
    The problem is the log says “D:\NewUnityProject\Library\DotsRuntimeBuild\artifacts\Stevedore\emscripten-llvm-win-x64\emscripten-llvm-e1.38.28-2019_04_05_07_52\clang++.exe --version' failed”
    So I use this command on win10, and you see, the result tells OK. I just wonder why the logs tell my "clang++.exe --version" failed? Whats the failed detail? Maybe version of clang++ no correct or anything else?
     
  39. Arowx

    Arowx

    Joined:
    Nov 12, 2009
    Posts:
    7,118
    Is this approach wrong? Because you are adding and removing a component from an entity therefore it will have to be moved in memory to a new group by the system.

    Would it not be better to have a StartExplosion* system that picks up a Boom entity and relocates an available disabled explosion to a new location and then enables it? As I image a Boom would just be a tag/type indicator and a location which should be much lighter on memory than an explosion.

    Then you are creating a data set that has one job and then can be disposed of as opposed to moving around the explosion data sets between two systems.

    *Ideally would it just be a MoveAndEnableSystem for all entities that are reused from a pool of dormant entities or created by a pooling system as needed.
     
  40. Opeth001

    Opeth001

    Joined:
    Jan 28, 2017
    Posts:
    291
    is it possible to use Project Tiny as a 3D Headless server or it's just available for 2D at this moment ? if no are you planning for it?
     
  41. louisgv

    louisgv

    Joined:
    Aug 7, 2013
    Posts:
    18
    I'm getting this error while trying to open the SpawnAndDestroy Dot project on 2019.2.0b7:

    ```
    Library\PackageCache\com.unity.tiny@0.15.3-preview\DotsModules\Unity.Tiny.Utils\SwitchRenderingSystem.cs(12,33): error CS0234: The type or namespace name 'HTML' does not exist in the namespace 'Unity.Tiny' (are you missing an assembly reference?)
    (edited)

    ```

    Any help would be much appreciated!
     
  42. gamayun

    gamayun

    Joined:
    Nov 20, 2012
    Posts:
    23
    I'd stick to 2019.2.0b3 for now...
     
  43. oceanxiao

    oceanxiao

    Joined:
    Jan 19, 2016
    Posts:
    10
  44. yossi_horowitz_artie

    yossi_horowitz_artie

    Joined:
    Jan 30, 2019
    Posts:
    60
    There are a lot of people over at the DOTS forum that can tell you way more about the intricacies of optimizing for ECS than I can, but the general impression that I have is that:

    - Moving an entity from one chunk to another as consequence of a component change is fairly inexpensive
    - Spawning and destroying entities is inexpensive enough that pooling is generally unnecessary.

    But don't take my word for either of these things; you should definitely go talk to the ECS mavens.
     
  45. MaNiC

    MaNiC

    Joined:
    Feb 18, 2013
    Posts:
    24
    Hi, I have the same issue. How did you resolve this?
     
  46. romiohasan

    romiohasan

    Joined:
    Apr 8, 2019
    Posts:
    13
    Getting the following error at random run-time during playing in browser with AsmJS build (debug or develop).

    Any idea what could be the reason for this error?

    Code (JavaScript):
    1. [libil2cpp] A managed exception was thrown. The Tiny runtime does not support managed exceptions.
    2. 44bafe32-f88a-4de0-a186-870c14777e80:19 [libil2cpp] The exception message is: System error.
    3. 44bafe32-f88a-4de0-a186-870c14777e80:19 [libil2cpp] No native stack trace exists. Make sure this is platform supports native stack traces.
    4.  
    5.  Uncaught trap!
    6.  
    7. abort    @    44bafe32-f88a-4de0-a186-870c14777e80:120
    8. _llvm_trap    @    44bafe32-f88a-4de0-a…6-870c14777e80:2549
    9. __ZN6il2cpp2os12CrashHelpers9CrashImplEv
     
  47. FtbDx

    FtbDx

    Joined:
    Jun 22, 2017
    Posts:
    1
    Library \ PackageCache \ com.unity.tiny@0.15.3-preview \ DotsModules \ Unity.Tiny.Utils \ SwitchRenderingSystem.cs(12,33):error CS0234:命名空间中不存在类型或命名空间名称“HTML” 'Unity.Tiny'(你错过了汇编参考吗?)
    为什么???
     
  48. davidpuetter

    davidpuetter

    Joined:
    Jul 4, 2019
    Posts:
    1
    I can't seem to build any project for anything but AsmJS
    DotNet & Il2CPP gives the following error:
    Code (CSharp):
    1. tundra: error: unable to map helloworld-windows-dotnet-debug to any named node or input/output file
    AsmJS builds sucessfully
    Wasm seems to build but crashes instantly when you load it, Chrome shows 'Aww Snap' page and shows nothing in console.
     
  49. Maras

    Maras

    Joined:
    Dec 11, 2012
    Posts:
    49
    Any news about the roadmap? Really excited about Tiny and the future of HTML5 games :)
     
    facundo_unity961 and GliderGuy like this.
  50. ibyte

    ibyte

    Joined:
    Aug 14, 2009
    Posts:
    915
    Hi I know this is a minor point but which is it Project Tiny or Tiny Mode? Depending on the Unity version I see the package named differently? Which is the latest?
     
Thread Status:
Not open for further replies.