how to create a new job:
Spoiler
crewReplacer_Main.getJob(String job)
returns: an crewReplacer_Job with the same name. or creates one if none exists.
job: is an ID that you wish for this job to have. most be no other jobs with this ID.
crewReplacer_Main.addOrMergeJob(crewReplacer_Job job);
you can also run this command. however, this is for people who want to create there own crewReplacer_Job class.
make sure to set your job.name first.
when running job data there is 3 commands you need to know:
to get available crew power:
Spoiler
crewReplacer_Job.getAvailableCrewPower(CampaignFleetAPI fleet)
returns: (float) the availableCrew * crewPower in this fleet
fleet: is the fleet that you want to get crew from.
to display available crew for this job:
Spoiler
crewReplacer_Job.displayCrewAvailable(CampaignFleetAPI fleet,TextPanelAPI text)
displays all the crew in the fleet to the inputted TextPanelAPI
fleet: is the fleet that you want to get crew from.
text: is the TextPanelAPI you want to display to
to apply and display crew losses for this job:
Spoiler
crewReplacer_Job.automaticlyGetDisplayAndApplyCrewLost(CampaignFleetAPI fleet,int crewPowerRequired, float crew_power_to_lose,TextPanelAPI text)
removes crew from the fleet, and displays how mush crew was lost to the inputed TextPanelAPI
fleet: is the fleet that you want to get crew from.
crewPowerRequired: an float that should be equal to the required amount of crew to complete this job.
crew_power_to_lose: the number of crew you want to remove from this fleet. should never be more then crewPowerRequired.
text: is the TextPanelAPI you want to display to