Open GabrielTavarez opened 2 years ago
See the changes in this PR if it helps: https://github.com/aviks/GameZero.jl/pull/38
The stuff in that PR should probably be better documented.
Hello, I have the same issue, everything works well when I have only one file, I face an error when trying to include
other files.
I tried following the instructions in the linked PR, but I get a LoadError: UndefRefError: access to undefined reference
.
Hello, I have the same issue, everything works well when I have only one file, I face an error when trying to
include
other files. I tried following the instructions in the linked PR, but I get aLoadError: UndefRefError: access to undefined reference
.
You can use game_include("yourefile.jl")
, as was added in #22. Documentation should probably be added for that, sorry
Thank you for your help, I'll try that ! Another solution I found is to put the external code inside a package/module.
Yeah, that works too
It would be great to have 1 file that contains the game and include other files that contains the structs created in the game.
I was tring to make a game.jl that had "include(snake.jl)".
In game.jl, all the loops and conditions would be verified, while the snake.jl file would have the definition of the struct snake and its methods. But when i try to do "include(snake.jl)" I get "LoadError: UndefVarError: include not defined".
Apperantly, there's no function "include" in gamezero, or it erases the base function from julia. I don't uderstand exactly