Large amounts of work on Rune
continuous-integration/drone/push Build is failing

This commit is contained in:
Deukhoofd committed 2024-05-08 15:46:09 +02:00
1 parent 4bc76b0ee4
commit 4ec07ca049
43 files changed
+979 -397

No files matched your search

+2 -1
View File
@@ -6,7 +6,8 @@ impl TestMove {
pub fn change_speed(self, choice, speed) {
println(`change_speed: ${choice.speed()}`);
println(`user level: ${choice.user().level()}`);
speed.value = 100;
println(`owner: ${self.owner.level()}`);
speed += 100;
}
}
+9 -1
View File
@@ -51,8 +51,16 @@ fn validate_library_load() {
fn rune_test() {
let result = library_loader::load_library();
let library = result.library;
let p1 = PokemonBuilder::new(library.clone(), "charizard".into(), 100)
.build()
.unwrap();
let script = library
.load_script(ScriptOwnerData::None, ScriptCategory::Move, &"TestMove".into())
.load_script(
ScriptOwnerData::Pokemon(p1.weak()),
ScriptCategory::Move,
&"TestMove".into(),
)
.unwrap()
.unwrap();
assert_eq!(script.name().unwrap().str(), "TestMove");