There's something that I'm trying to do that D may or may not be
capable of.
In the Map class, there is a 2-dimensional array called `grid`,
where the Tile objects are stored. The Mission class inherits the
Map class.
In the Mission class, I want the `grid` array to instead be
composed of
I have made some progress on this. For the raylib front-end, I
tried making a class called `Mission` which inherits `Map`. This
class handles the graphics, input, and other game events. The
program now compiles without errors, and there are some graphics.
I have pushed these updates to the
On Friday, 1 March 2024 at 05:07:24 UTC, Liam McGillivray wrote:
I don't know how best to organize the code. So far I have been
oo ideas
for a 2nd opinion:
https://github.com/crazymonkyyy/raylib-2024/blob/master/docs/examplecode.md
Theres not a good learning resource but "data oirented
I now have the Raylib functions working by using `toStrinz`.
I pushed some updates to the repository. I made the main project
a source library so that I can experiment with different graphics
library front-ends. I put have the front-end using Raylib in the
`raylib_frontend` directory. It
Examples were moved, so it‘s in the same place now:
- https://github.com/schveiguy/raylib-d
- https://github.com/schveiguy/raylib-d_examples
On Wednesday, 28 February 2024 at 07:56:16 UTC, Liam McGillivray
wrote:
```
DrawText("Open Emblem", 180, 300, 64, Colors.RAYWHITE);
```
So why is it that one of these functions, but not the other is
allowing D strings in place of C-style strings?
C is expecting null-terminated chars. D
There's something very strange going on when using Raylib-D.
I tried using the raylib function `LoadTexture` like this:
```
tileSprites[i] = LoadTexture("../sprites/" ~ spriteName);
```
I got the following error:
```
Error: function `raylib.LoadTexture(const(char)* fileName)` is
not callable
On Tuesday, 27 February 2024 at 22:05:48 UTC, Liam McGillivray
wrote:
Looking at the code examples on the Raylib and SFML website,
they look similar in complexity of getting started, but I like
it that the Raylib website has lots of simple demonstration
programs on the website with the code
On Tuesday, 27 February 2024 at 03:43:56 UTC, Liam McGillivray
wrote:
Raylib looks promising. I installed it along with your
Raylib-d. I managed to build the example you provided with dub,
but trying to use it in it's own dub project in a separate
directory isn't working. Just copying and
On Tuesday, 27 February 2024 at 03:06:19 UTC, Steven
Schveighoffer wrote:
If you are going for game development, I would recommend
raylib-d (https://code.dlang.org/packages/raylib-d), which is
my wrapper around the very good raylib library.
For doing GUI, raygui is supported, but I also can
On Monday, 26 February 2024 at 23:27:49 UTC, Liam McGillivray
wrote:
I don't know whether I should continue this topic or start a
new one now that the problem mentioned in the title is fixed. I
have now uploaded some of the code to [a GitHub
repository](https://github.com/LiamM32/Open_Emblem).
On Monday, 26 February 2024 at 22:40:49 UTC, Liam McGillivray
wrote:
On Sunday, 25 February 2024 at 03:23:03 UTC, Paul Backus wrote:
You can't give a class the same name as the file it's in. If
you do, then when you try to use it from another file, the
compiler will get confused and think
I don't know whether I should continue this topic or start a new
one now that the problem mentioned in the title is fixed. I have
now uploaded some of the code to [a GitHub
repository](https://github.com/LiamM32/Open_Emblem).
To make this game usable, I will need a library for graphics and
On Sunday, 25 February 2024 at 03:23:03 UTC, Paul Backus wrote:
You can't give a class the same name as the file it's in. If
you do, then when you try to use it from another file, the
compiler will get confused and think you're referring to the
file instead of the class (that's what "import is
On Saturday, 24 February 2024 at 10:31:06 UTC, Liam McGillivray
wrote:
`Unit.d` & `Map.d` are longer files. `Map.d` begins with
`import Tile;`, and `Unit.d` begins with `import Map;`.
Why are the errors happening? What's the problem? Why is it
`currentclass.importedclass` instead of simply
On 24/02/2024 11:51 PM, Liam McGillivray wrote:
On Saturday, 24 February 2024 at 10:34:25 UTC, Richard (Rikki) Andrew
Cattermole wrote:
A few things.
Module names should be lower case.
I capitalised the first letter in the class names so that I can make
instances of them in lowercase.
On Saturday, 24 February 2024 at 10:34:25 UTC, Richard (Rikki)
Andrew Cattermole wrote:
A few things.
Module names should be lower case.
I capitalised the first letter in the class names so that I can
make instances of them in lowercase. Should I rename the classes,
modules, and filenames
A few things.
Module names should be lower case.
Each file, needs the full module declaration.
source/foo/bar.d:
```d
module foo.bar;
```
source/app.d:
```d
module app;
import foo.bar;
```
Directories matter, this allows the import path search (via the use of
the -I switch) to
I am trying to make a tactical role-playing game which I am
likely to open-source. Right now the code is very simple, with
only 3 files each containing a class with the same name.
The files are `Map.d`, `Tile.d`, and `Unit.d`. Each of these
files contains an `import` line to access one of the
19 matches
Mail list logo