Anyone been able to add functional staff?
Moderator: NBJeff
Anyone been able to add functional staff?
I've been able to add new staff to the menu but all I get is a sideways staff member that doesn't move nor show up properly. Also, can't figure out how to set wages.
Re: Anyone been able to add functional staff?
The reason he's sideways is because you probably set the rotatetype wrong and the reason he doesn't move is because he doesn't need to move.
The is no reason for him to move as he's not coded to wander around when he's idle and probably doesn't have a job
The is no reason for him to move as he's not coded to wander around when he's idle and probably doesn't have a job
Re: Anyone been able to add functional staff?
Idk, according to previous experiences with actual system administrators, this guy seems to be working exactly correctly.
Re: Anyone been able to add functional staff?
knoest26 wrote:The reason he's sideways is because you probably set the rotatetype wrong and the reason he doesn't move is because he doesn't need to move.
The is no reason for him to move as he's not coded to wander around when he's idle and probably doesn't have a job
Ah, what should it be set to? I never could understand rotatetype
Re: Anyone been able to add functional staff?
dsdude123 wrote:Ah, what should it be set to?
0,0
Re: Anyone been able to add functional staff?
Phraxas wrote:dsdude123 wrote:Ah, what should it be set to?
0,0
Already was set to 0. Seems that setting it to 4 solved the problem.
Re: Anyone been able to add functional staff?
knoest26 wrote:The reason he's sideways is because you probably set the rotatetype wrong and the reason he doesn't move is because he doesn't need to move.
The is no reason for him to move as he's not coded to wander around when he's idle and probably doesn't have a job
It seems that even when there is a job that the staff should do, they don't. Perhaps the modding system isn't ready for new staff yet.
-
- level1
- Posts: 15
- Joined: Tue Oct 30, 2012 11:24 pm
- Location: United Kingdom
- Contact:
Re: Anyone been able to add functional staff?
Well adding Guards crashes every single time
Re: Anyone been able to add functional staff?
. . . I haven't even gotten them to show in the menu like that. Could you fill me in on how you did that? Thanks!
Re: Anyone been able to add functional staff?
Entities seem to have a "JobId" property, and all jobs are given a number. Unfortunately, I don't think you can actually get the JobId for a given job, as Object.CreateJob() doesn't return anything. There may still be other ways to assign jobs, which I am looking into right now. I'll update with more info.
EDIT: Annnnnnnd it took me all of 20 seconds! If you define the job with the "Worker" attribute as the name of your entity, the entity should move to perform the job.
EDIT: Annnnnnnd it took me all of 20 seconds! If you define the job with the "Worker" attribute as the name of your entity, the entity should move to perform the job.
Re: Anyone been able to add functional staff?
About the rotatetypes, it goes like this
0: It's facing forward
1: Orientated to the left
2: Orientated to the back
3: Orientated to the right
4: Not rotatable
0: It's facing forward
1: Orientated to the left
2: Orientated to the back
3: Orientated to the right
4: Not rotatable
Re: Anyone been able to add functional staff?
pcgrosen wrote:Entities seem to have a "JobId" property, and all jobs are given a number. Unfortunately, I don't think you can actually get the JobId for a given job, as Object.CreateJob() doesn't return anything. There may still be other ways to assign jobs, which I am looking into right now. I'll update with more info.
EDIT: Annnnnnnd it took me all of 20 seconds! If you define the job with the "Worker" attribute as the name of your entity, the entity should move to perform the job.
Worker attribute as the name? Not sure I quite understand you, can you post the code?
Re: Anyone been able to add functional staff?
That's just going to create another worker though.
Re: Anyone been able to add functional staff?
Here's what I mean:
This is from the Vegetable Patch example mod. You could change the "Worker" line to something like this:
That would call the Systems Administrator to tend the vegetables. If you changed the other lines, too, you could come up with a more fitting job:
Then, inside of your script, you can call the function to create a job:
I believe that would give you a functioning job for your System Administrator to perform.
Code: Select all
BEGIN Job
Name TendVegetables
JobTime 0.1
Tool Trowel
Worker Prisoner
Qualification Horticulture
END
This is from the Vegetable Patch example mod. You could change the "Worker" line to something like this:
Code: Select all
Worker SystemAdministrator
That would call the Systems Administrator to tend the vegetables. If you changed the other lines, too, you could come up with a more fitting job:
Code: Select all
BEGIN Job
Name RepairComputer
JobTime 1.0
Tool Screwdriver
Worker SystemAdministrator
END
Then, inside of your script, you can call the function to create a job:
Code: Select all
Object.CreateJob("RepairComputer")
I believe that would give you a functioning job for your System Administrator to perform.
Re: Anyone been able to add functional staff?
pcgrosen wrote:Here's what I mean:Code: Select all
BEGIN Job
Name TendVegetables
JobTime 0.1
Tool Trowel
Worker Prisoner
Qualification Horticulture
END
This is from the Vegetable Patch example mod. You could change the "Worker" line to something like this:Code: Select all
Worker SystemAdministrator
That would call the Systems Administrator to tend the vegetables. If you changed the other lines, too, you could come up with a more fitting job:Code: Select all
BEGIN Job
Name RepairComputer
JobTime 1.0
Tool Screwdriver
Worker SystemAdministrator
END
Then, inside of your script, you can call the function to create a job:Code: Select all
Object.CreateJob("RepairComputer")
I believe that would give you a functioning job for your System Administrator to perform.
Already tried that didn't work
Who is online
Users browsing this forum: No registered users and 6 guests