hecrj / coffee

An opinionated 2D game engine for Rust
https://docs.rs/coffee
MIT License
1.08k stars 55 forks source link

`coffee::graphics::window::settings::Settings` does not have this field | function or associated item not found in `coffee::load::task::Task<_>` | Coffee Minimal Example #122

Closed WhatWithCheeze432 closed 4 years ago

WhatWithCheeze432 commented 4 years ago

Log:

usr@debian:~/code/rust/program$ cargo run
   Compiling program v0.0.1 (/home/usr/code/rust/program)
error[E0560]: struct `coffee::graphics::window::settings::Settings` has no field named `maximized`
  --> src/main.rs:11:9
   |
11 |         maximized: false,
   |         ^^^^^^^^^ `coffee::graphics::window::settings::Settings` does not have this field
   |
   = note: available fields are: `title`, `size`, `resizable`, `fullscreen`

error[E0599]: no function or associated item named `succeed` found for type `coffee::load::task::Task<_>` in the current scope
  --> src/main.rs:25:15
   |
25 |         Task::succeed(|| MyGame { /* ... */ })
   |               ^^^^^^^ function or associated item not found in `coffee::load::task::Task<_>`

error: aborting due to 2 previous errors

Some errors have detailed explanations: E0560, E0599.
For more information about an error, try `rustc --explain E0560`.
error: could not compile `program`.

To learn more, run the command again with --verbose.
usr@debian:~/code/rust/program$ 

File Source Code:

Was made in accordance with the minimal example.

hecrj commented 4 years ago

You are probably using the examples in master, which can contain breaking changes. The README mentions it:

Coffee moves fast and the master branch can contain breaking changes! If you want to learn about a specific release, check out the release list.