GitHub Documentation Patreon donate button

Raspberry PI and Colyseus ( and Haxe)



  • neko compiled with no problem but haxe puked during make. Likely the differince in Armbian vs Raspbian distros but I had to install camlp4o (sudo apt-get install camlp4-extra). Haxe installed fine afterwords. Working on the rest now...



  • currently stuck with the following error when running haxe server.hxml

    /usr/lib/haxe/lib/tink_core/1,24,0/src/tink/core/Error.hx:116: characters 9-21 : Class<Std> has no field downcast
    src/MainServer.hx:3: characters 8-30 : Type not found : colyseus.server.Server
    


  • what does ' haxelib list ' show?

    I had to use a mix of steps ( haxelib install and copying files) before haxe server.hxml could find all types.



  • ~/colyseus-hxjs-examples$ haxelib list
    colyseus-hxjs: [git] haxelib.json src extraParams.hxml README.md
    hxnodejs: [10.0.0]
    tink_core: [1.24.0]
    tink_lang: [0.6.2]
    tink_macro: [0.17.7]
    tink_priority: [0.1.4]
    tink_syntaxhub: [0.4.3]
    


  • @closetmonkey
    Hmm that is a strange output of haxelib list on colyseus-hxjs

    From memory (I don't have access to it now since I'm at work) the colyseus-hxjs should only have one version behind it :
    colyseus-hxjs: [git]

    this was used to tell haxelib what version it should use:
    echo "git" > /usr/lib/haxe/lib/colyseus-hxjs/.current

    what is the contents of your .current file?!

    Maybe you just edit the /usr/lib/haxe/lib/ (or your own haxelib path) /colyseus-hxjs/.current and make sure it only has the git in it?!



  • @mdotedot said in Raspberry PI and Colyseus ( and Haxe):

    ... /usr/lib/haxe/lib/colyseus-hxjs/.current

    '/usr/lib/haxe/lib/colyseus-hxjs/.current' has one line with the contents of 'git'. Interestingly, haxelib.json src extraParams.hxml README.md is the directory contents at /usr/lib/haxe/lib/colyseus-hxjs/.

    ~/colyseus-hxjs-examples$ ls /usr/lib/haxe/lib/colyseus-hxjs/
    extraParams.hxml  git  haxelib.json  README.md  src
    


  • Unfortunately I can't confirm now on my system, but you might try to move the contents of that hxjs directory to the [git] (or copy)
    So that /usr/lib/haxe/lib/colyseus/-hxjs/git has the src, haxelib.json, README.md and extraParams.hxml

    And then try again haxe server.hxml



  • That did it, however, I now get the following errors

    ~/colyseus-hxjs-examples$ haxe server.hxml
    /usr/lib/haxe/lib/tink_core/1,24,0/src/tink/core/Error.hx:116: characters 9-21 : Class<Std> has no field downcast
    src/server/rooms/StateHandlerRoom.hx:5: characters 1-51 : Module colyseus.server.schema.Schema does not define type MapSchemaUtil
    src/server/rooms/StateHandlerRoom.hx:5: characters 1-51 : For function argument 'handler'
    src/MainServer.hx:7: lines 7-41 : Defined in this class
    


  • Not sure if you are mixing libraries. The stuff that I rely on is from serjek and was based on 0.10 release. There is now a 0.11 release so I hope you didn't load any of that?!



  • From my setup:

    root@raspberrypi:~/colyseus-hxjs-examples# haxe -version

    4.0.0-rc.2
    

    root@raspberrypi:~/colyseus-hxjs-examples# haxelib list

    colyseus-hxjs: [git]
    hxnodejs: [10.0.0]
    tink_core: [1.23.0]
    tink_lang: [0.6.2]
    tink_macro: [0.17.7]
    tink_priority: [0.1.4]
    tink_syntaxhub: [0.4.3]
    

    root@raspberrypi:~/colyseus-hxjs-examples# cat src/colyseus/server/schema/Schema.hx | grep MapSchemaUtil

    class MapSchemaUtil {
    

    Your tink_core is different than mine. Don't know if that is the only thing that is different?


 

GitHub Documentation Patreon donate button

© 2019 Endel Dreyer