DR rs 0.2.14.0
This commit is contained in:
parent
0a264c603d
commit
c20f4cd85f
@ -3,13 +3,26 @@
|
||||
|
||||
- 最新版本号
|
||||
- DR game: 0.2.0.0
|
||||
- DR rs: 0.2.13.0
|
||||
- DR rs: 0.2.14.0
|
||||
|
||||
## DR rs 0.2.14.0
|
||||
|
||||
### 删除
|
||||
|
||||
- 删除了多个 xml 测试读取函数
|
||||
- Remove multiple xml test read functions
|
||||
|
||||
### 改进
|
||||
|
||||
- 改进了 xml writer 的 `SR1Ship` 写入
|
||||
- Improve the xml writer's `SR1Ship` write
|
||||
|
||||
## DR game 0.2.1.0
|
||||
|
||||
### 修改
|
||||
|
||||
- 将 `sr1_ship` 中的 `Camera_rs` 改为 `Difficult_Rocket.utils.camera.Camera`
|
||||
- Change `Camera_rs` in `sr1_ship` to `Difficult_Rocket.utils.camera.Camera`
|
||||
|
||||
## DR rs 0.2.13.0
|
||||
|
||||
@ -18,12 +31,23 @@
|
||||
- 删除了 `render.rs`
|
||||
- 没必要拿 rust 写这玩意(
|
||||
- 用 `DR game` 的 `camera` 代替
|
||||
- Delete `render.rs`
|
||||
- No need to write this thing with rust (
|
||||
- Use `DR game`'s `camera` instead
|
||||
|
||||
### 添加
|
||||
|
||||
- 添加了 基于 `quick-xml::writer::Writer` 的 xml `SR1Ship` 写入
|
||||
- 折磨啊啊啊啊啊啊啊啊
|
||||
- Add xml `SR1Ship` write based on `quick-xml::writer::Writer`
|
||||
- Torture ah ah ah ah ah ah ah ah
|
||||
|
||||
## DR rs 0.2.12.0
|
||||
|
||||
### 添加
|
||||
|
||||
- 添加了 xml 的读取测试
|
||||
- Add xml read test
|
||||
|
||||
## DR game 0.1.2.0
|
||||
|
||||
|
@ -12,7 +12,7 @@ package_path = 'Difficult_Rocket_rs'
|
||||
|
||||
setup(
|
||||
name='Difficult_Rocket_rs',
|
||||
version="0.2.11.0",
|
||||
version="0.2.14.0",
|
||||
author='shenjackyuanjie',
|
||||
author_email='3695888@qq.com',
|
||||
rust_extensions=[RustExtension(target="Difficult_Rocket_rs.Difficult_Rocket_rs",
|
||||
|
@ -25,7 +25,7 @@ enum LoadState {
|
||||
}
|
||||
|
||||
#[pyfunction]
|
||||
fn get_version_str() -> String { "0.2.13.0".to_string() }
|
||||
fn get_version_str() -> String { "0.2.14.0".to_string() }
|
||||
|
||||
#[pyfunction]
|
||||
fn test_call(py_obj: &PyAny) -> PyResult<bool> {
|
||||
|
@ -782,8 +782,8 @@ pub mod sr1 {
|
||||
("flippedY", part.flip_y.to_string().as_str())
|
||||
);
|
||||
part_attr.push_attribute(("activated", part.active.to_string().as_str()));
|
||||
writer.write_event(Event::Start(part_attr)).unwrap();
|
||||
match part.part_type {
|
||||
// writer.write_event(Event::Start(part_attr)).unwrap();
|
||||
let inner_attr: Option<BytesStart> = match part.part_type {
|
||||
SR1PartTypeEnum::tank | SR1PartTypeEnum::engine => {
|
||||
let mut tank_attr = BytesStart::new({
|
||||
if part.part_type == SR1PartTypeEnum::tank {
|
||||
@ -793,11 +793,35 @@ pub mod sr1 {
|
||||
}
|
||||
});
|
||||
tank_attr.push_attribute(("fuel", part.attr.fuel.unwrap().to_string().as_str()));
|
||||
writer.write_event(Event::Empty(tank_attr)).unwrap();
|
||||
Some(tank_attr)
|
||||
}
|
||||
SR1PartTypeEnum::solar => {
|
||||
part_attr.push_attribute(("extension", part.attr.extension.unwrap().to_string().as_str()));
|
||||
None
|
||||
}
|
||||
SR1PartTypeEnum::parachute => {
|
||||
part_attr.push_attribute(("chuteX", part.attr.chute_x.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("chuteY", part.attr.chute_y.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("chuteHeight", part.attr.chute_height.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("chuteAngle", part.attr.chute_angle.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("inflate", part.attr.inflate.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("inflation", part.attr.inflation.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("deployed", part.attr.deployed.unwrap().to_string().as_str()));
|
||||
part_attr.push_attribute(("rope", part.attr.rope.unwrap().to_string().as_str()));
|
||||
None
|
||||
}
|
||||
_ => None,
|
||||
};
|
||||
match inner_attr {
|
||||
Some(inner_attr) => {
|
||||
writer.write_event(Event::Start(part_attr)).unwrap();
|
||||
writer.write_event(Event::Empty(inner_attr)).unwrap();
|
||||
writer.write_event(Event::End(BytesEnd::new("Part"))).unwrap();
|
||||
}
|
||||
None => {
|
||||
writer.write_event(Event::Empty(part_attr)).unwrap();
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
writer.write_event(Event::End(BytesEnd::new("Part"))).unwrap();
|
||||
}
|
||||
writer.write_event(Event::End(BytesEnd::new("Parts"))).unwrap();
|
||||
}
|
||||
|
@ -17,7 +17,7 @@ from Difficult_Rocket.api.mod import ModInfo
|
||||
from Difficult_Rocket.client import ClientWindow
|
||||
from Difficult_Rocket.api.types import Options, Version
|
||||
|
||||
DR_rust_version = Version("0.2.13.0") # DR_mod 的 Rust 编写部分的兼容版本
|
||||
DR_rust_version = Version("0.2.14.0") # DR_mod 的 Rust 编写部分的兼容版本
|
||||
|
||||
logger = logging.getLogger('client.dr_game')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user