change encode function names to be consistent
This commit is contained in:
parent
655cbda1c9
commit
5c17f1c21e
2 changed files with 7 additions and 7 deletions
|
@ -38,7 +38,7 @@ pub fn encode_namedata(general_params: &mut FuncParams, real_name: &str) {
|
||||||
.encode(general_params.fr_ver, general_params.fr_out)
|
.encode(general_params.fr_ver, general_params.fr_out)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
}
|
}
|
||||||
pub fn encode_ids(general_params: &mut FuncParams, real_ids: Vec<Identificationer>, idsmap: HashMap<String, u8>) {
|
pub fn encode_iddata(general_params: &mut FuncParams, real_ids: Vec<Identificationer>, idsmap: HashMap<String, u8>) {
|
||||||
let mut idvec = Vec::new();
|
let mut idvec = Vec::new();
|
||||||
for eachid in real_ids {
|
for eachid in real_ids {
|
||||||
let id_id = idsmap.get(eachid.id.trim());
|
let id_id = idsmap.get(eachid.id.trim());
|
||||||
|
@ -69,7 +69,7 @@ pub fn encode_ids(general_params: &mut FuncParams, real_ids: Vec<Identificatione
|
||||||
.encode(general_params.fr_ver, general_params.fr_out)
|
.encode(general_params.fr_ver, general_params.fr_out)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
}
|
}
|
||||||
pub fn encode_powder(general_params: &mut FuncParams, real_powders: Vec<Powder>) {
|
pub fn encode_powderdata(general_params: &mut FuncParams, real_powders: Vec<Powder>) {
|
||||||
let mut powdervec = Vec::new();
|
let mut powdervec = Vec::new();
|
||||||
for eachpowder in real_powders {
|
for eachpowder in real_powders {
|
||||||
let powderamount: u8 = eachpowder.amount.unwrap_or(1);
|
let powderamount: u8 = eachpowder.amount.unwrap_or(1);
|
||||||
|
@ -105,7 +105,7 @@ pub fn encode_powder(general_params: &mut FuncParams, real_powders: Vec<Powder>)
|
||||||
.encode(general_params.fr_ver, general_params.fr_out)
|
.encode(general_params.fr_ver, general_params.fr_out)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
}
|
}
|
||||||
pub fn encode_reroll(general_params: &mut FuncParams, rerollcount: u8) {
|
pub fn encode_rerolldata(general_params: &mut FuncParams, rerollcount: u8) {
|
||||||
if rerollcount != 0 {
|
if rerollcount != 0 {
|
||||||
// ENCODE: RerollData if applicable
|
// ENCODE: RerollData if applicable
|
||||||
RerollData(rerollcount)
|
RerollData(rerollcount)
|
||||||
|
@ -116,7 +116,7 @@ pub fn encode_reroll(general_params: &mut FuncParams, rerollcount: u8) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
pub fn encode_shiny(general_params: &mut FuncParams, shiny: Shinyjson, json_shiny: Vec<Shinystruct>) {
|
pub fn encode_shinydata(general_params: &mut FuncParams, shiny: Shinyjson, json_shiny: Vec<Shinystruct>) {
|
||||||
let mut realshinykey: u8;
|
let mut realshinykey: u8;
|
||||||
let _shinykey = &shiny.key;
|
let _shinykey = &shiny.key;
|
||||||
let shinyvalue = shiny.value;
|
let shinyvalue = shiny.value;
|
||||||
|
|
|
@ -154,7 +154,7 @@ fn cook(
|
||||||
match json_config.item_type {
|
match json_config.item_type {
|
||||||
ItemTypeDeser::Gear | ItemTypeDeser::Tome | ItemTypeDeser::Charm => {
|
ItemTypeDeser::Gear | ItemTypeDeser::Tome | ItemTypeDeser::Charm => {
|
||||||
if let Some(real_ids) = json_config.ids {
|
if let Some(real_ids) = json_config.ids {
|
||||||
encode_ids(&mut fr_params, real_ids, idsmap)
|
encode_iddata(&mut fr_params, real_ids, idsmap)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
|
@ -164,7 +164,7 @@ fn cook(
|
||||||
match json_config.item_type {
|
match json_config.item_type {
|
||||||
ItemTypeDeser::Gear | ItemTypeDeser::CraftedGear => {
|
ItemTypeDeser::Gear | ItemTypeDeser::CraftedGear => {
|
||||||
if let Some(real_powders) = json_config.powders {
|
if let Some(real_powders) = json_config.powders {
|
||||||
encode_powder(&mut fr_params, real_powders)
|
encode_powderdata(&mut fr_params, real_powders)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
|
@ -175,7 +175,7 @@ fn cook(
|
||||||
ItemTypeDeser::Gear | ItemTypeDeser::Tome | ItemTypeDeser::Charm => {
|
ItemTypeDeser::Gear | ItemTypeDeser::Tome | ItemTypeDeser::Charm => {
|
||||||
if let Some(rerollcount) = json_config.rerolls {
|
if let Some(rerollcount) = json_config.rerolls {
|
||||||
// rerolldata
|
// rerolldata
|
||||||
encode_reroll(&mut fr_params, rerollcount)
|
encode_rerolldata(&mut fr_params, rerollcount)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
_ => {}
|
_ => {}
|
||||||
|
|
Loading…
Add table
Reference in a new issue