This mod replaces your character with a female version of the engineer, Gear Girl!
Small changes concerning balance, gameplay, or graphics.
Title say it all, I'm currently doing a s YT series with a female player, and it would be perfect if SHE could be the female engineer and myself be the male engineer.
Also i loved the mod so much I had to do a video on it here: https://youtu.be/N5jsph0ww0A
+1 ... and maybe it's even a console command to switch one's character, kinda like /color. (/gender ??)
+1 yes please :)
https://mods.factorio.com/mod/GearGirlSelect
I have created an experimental version of this mod that lets you select the character, but I wont implement it into the main mod until I can make a better version.
Important detail: Once the character selector is finished and implemented onto the main mod, you'll have to do a few things in your saves with the temporal version of the mod I linked in this thread
1) Make a backup
2) Place all your items in a chest
3) Kill your character, respawn
4) Activate the new mod and deactivate the old mod
that should prevent any of your items from being lost, or you having no character and thus getting put on godmode
as much as i like the Gear Girl, i currently also play with "Mining Drones" (this results in a swarm of Klonans of your own char to do the work, really nice and funny; i call them Klonans instead of clones since that mod is by Klonan :-) and there is another mod ("I, Robot") that replaces your character with the compilatron, thus having a neutral char to use. a third mod also works nicely together with these two: Construction Drones (also by Klonan) which adds a swarm of compilatrons as early bots. using those three mods together now makes me a big compilatron boss, with lots of swarms of compilatrons for mining and construction work.
would it somehow be possible to join forces to be able to combine (and select and switch) noit only male and female chars from this mod, but also the compilatron from "I,Robot", maybe even with an option to later easily add even more alternate chars ?
Adding to what Anson said, would it be in any way possible to make Klonan's mining drones (and gun and missile infantry from Total Automization) use the default engineer, while the player use the Gear Girl engineer?
I wish I could help but I can't seem to figure out the code, I don't have any experience with programming in LUA. If anyone was willing to make a template mod that could easily implement multiple characters, I'd be happy to provide them with the gear girl graphics.
@SleepyEngi - does this mean your giving up on making a character switcher? Even with the problems with Inventory Clearing - I would like the ability to replace only one character in a multiplayer game's icon (or maybe make it where it's only displayed locally, so everyone else sees their own Character Mod - don't know if that's possible); My Friends would kill me if I forced them to use this but at the same time a female model is something that makes the game easier to play for me. (Albeit I prefer the Nepgear Model - still it doesn't have color-shift or custom armor so go figure)
https://mods.factorio.com/mod/RitnCharacters
works well ;)
Hi! I'm the new owner of the minime-Mod. I've just made the code way easier by not recreating the character from the base mod, but using what's available and just changing the things that need changing. Fortunately, that allowed me to fulfill a request to make the mod compatible with Gear Girl Character.
I wish I could help but I can't seem to figure out the code, I don't have any experience with programming in LUA. If anyone was willing to make a template mod that could easily implement multiple characters, I'd be happy to provide them with the gear girl graphics.
I've given some thought to that. It really shouldn't be too hard to make characters exchangeable, and to allow multiplayer games with different characters (as requested by JD-Plays). I think it could even be possible to allow players to change their appearance during the game. I'd like to integrate that into minime at some point, but I would need some help from your side.
Let me explain: The way our mods currently work, we just overwrite (parts of) data.raw.character.character. RitnCharacters (linked to by Fr_Dae) is even worse: It waits for your mod to overwrite data.raw.character.character with the Gear Girl graphics, then recreates the character from vanilla as data.raw.character["character-base"] and offers you to choose your character each time you start a new game or your character respawns. That's not very efficient.
The solution is simple: Don't overwrite data.raw.character.character -- at least not immediately! Instead, create your character in data.lua under another name, e.g. data.raw.character["GearGirl-character"]. This would give me the chance to scale the graphics of both the vanilla and your character during data-updates.lua. Finally, in data-final-fixes.lua, you could check if my mod (or any other mod that allows choosing a character) is active. If not, you can overwrite the character from vanilla:
if not (mods["minime"] or mods[Other_mod_for_choosing_characters]) then
data.raw.character.character = data.raw.character["GearGirl-character"]
data.raw.character.character.name = "character"
data.raw.character["GearGirl-character"] = nil
end
The beautiful thing about this is, it wouldn't even mess with RitnCharacters because all it does during the data stage is recreating the vanilla character under another name. (In fact, the data stage part could be removed from that mod, as changing characters during the game is strictly a control stage thing, so RitnCharacters could even benefit by becoming smaller and loading a tad faster.) Moreover, you wouldn't have to provide any graphics to anybody because everything other mods need is already there!
Would you be open to this suggestion?
EDIT: Inserted line to change the character name to "character" if Gear Girl is used as stand-alone mod.
If you can do it, go for it @Pi-C
@SleepyEngi: If you can add the changes I suggested, I will! :-)
Perhaps we should settle on a better character name: e.g. "GearGirl-character-skin". Mods may create character entities for different purposes -- for example, AAI Programmable vehicles and Autodrive insert dummy characters into vehicles so they can shoot at enemies and open gates.
I could manually compile a list of alternative characters from the mods I'm aware of and add them to the GUI. However, it would be more elegant if the list could be compiled automatically -- but I'd need some string in the names that allows me to distinguish between new characters like Gear Girl and dummy characters that are just a copy of the vanilla kind. (Another way would be to let mods register their characters with mine, but that would require you to add a control script.)
By the way: I've been offered collaborator status on "I, Robot", so I could start testing with that. Laying the foundation (i.e. GUI code, listening to events etc.) is the hard part, but once that's in place, it should be easy to use it for other characters as well.
i don't have realy understand what are the probleme with the mod of ritn ?
i don't have realy understand what are the probleme with the mod of ritn ?
It works fine with Gear Girl, but if you read this thread, there are several mods that let you change your character, and I think it would be neat if you could pick your character from all that are available. Also, Ritn only works on starting a game (not sure, perhaps also on loading?), and when you respawn after having been killed. My plan was to allow players to change their character at any time.
If you're referring to my comment about the inefficient way it does things: Yes, it is inefficient. Unfortunately, it is the only way it can be done as long as Gear Girl overwrites the base character right away. So please understand that I don't mean to make fun of the Ritn mod, and that I don't say the mod author is stupid. The mod does what it's supposed to do, and it uses the only way available to get there -- but if the way is full of potholes, you can only go slowly. :-)
ok, i understand , thanks for your reply =)
@Pi-C and SleepyEngi if this/another mod can be updated to work before 1.0 drops so 2 players can run different skins, i know of at least 2 different playthrus that will feature players running different skins!
I have an idea about how to do the character selection using mod settings, don't know if it is possible yet. Will research
i have a working prototype, but i haven't tested it in multiplayer yet, once i get it tested with someone i will make sure everything works and report back
My prototype is also almost working. :-)
i have confirmed my prototype works just like i want it to:
https://cdn.discordapp.com/attachments/361610217848307722/736517851799879700/unknown.png
https://cdn.discordapp.com/attachments/361610217848307722/736517952580354128/unknown.png
only thing i need now is to fix the assets and do some locale stuff
@SleepyEngi
i have my mod to a level where i would be comfortable with releasing it, but i have a few question about what you want
github: https://github.com/SpaceCat-Chan/Factorio_CharSelect
how do you want the mods to work together?
do you want one to be merged into the other, or do they stay seperate?
if they get merged, do you want full ownership over the end result? partial? none?
or would you rather use someone elses solution to this problem?
If I may chime in here again: I've been testing my version with "I, Robot" (collaborating there, so I've adjusted it not to overwrite the base character). Basically, it works like I've outlined above, and IF @SleepyEngi would be willing to make the changes I suggested, I think it would make life easier for everybody.
@SleepyEngi: Can I reach you on the forum? I've made the code for "I, Robot" in a very general way, so I'd like to send you the relevant files. You could either just reuse the code, or adapt it as you see fit. Although I'm only searching for "minime" now before deciding whether "I, Robot" is used as stand-alone mod and should overwrite the main character, this can be very easily changed. I already iterate over a table of known character-selection mods, so you'd just need to add to the list to make other mods compatible as well.
@SpaceCat-Chan: No worry, I don't want to throw you out of the game with that. I think our mods are different enough to be able to coexist. Also, my suggestion that Gear Girl not overwrite the base character would allow you to make your mod leaner as well.
@Pi-C all my mod cares about is that all allowed values for the mod-setting "Selected-Character" are valid character names, other mods just need to expand the list of allowed values and create another character prototype.
I even included a script that sets up most of a mod that adds new characters
@SpaceCat-Chan: Just wondering, do you take care of sieving out characters that may not be meant to play with? Mods may create new characters for other purposes, so they wouldn't care about changing their appearance.
If it ain't listed in the allowed values it will be ignored
@JD-Plays: I just uploaded my new version of minime and I, Robot. Here's a screenshot:
I've tested this locally in multiplayer mode. It seems to work now (there was a lot of desyncing in the beginning, but after some changes, that is gone for good). Exchanging the characters is completely safe. Even if the character you've used in your last session has been removed from the game, the items in your inventories and the settings (slot filters, personal logistics and auto-trash) will not be changed and are automatically transferred to the default character (the one you'll get automatically assigned as fall-back).
The new version of "minime" can be used with "Gear Girl Character". However, as long as Gear Girl overwrites the default character, you'll need at least one other mod providing a new character -- otherwise, there's nothing to choose from! (In this case, the character switching GUI won't be created, by the way.)
@SleepyEngi: As outlined above, you'd need to create your character in two stages (data.lua + data-final-fixes.lua), and you should not overwrite data.raw.character["character"] if "minime" is active. To avoid finding dummy characters, my mod looks for characters with the string "skin" (case doesn't matter, mixing capital and small letters is OK) in their name. In "I, Robot", I've named the character "IRobot_character_skin". If you'd use a name containing the pattern, "minime" would be able to find your character. Also, it would be extremely nice if you could localise the character name! If you take a closer look at the screenshot, you'll see an "Unknown key" message on the last button of the GUI. This makes it hard to settle for a new character. :-D
I've used this in my locale file:
[entity-name]
IRobot_character=I, Robot
and this in data-final-fixes.lua:
data.raw.character["IRobot_character_skin"].localised_name = {"entity-name.IRobot_character"}
One more thing I noticed during testing: Since Factorio 0.18.23, we have player footprints (look for footprint_particles). Gear Girl doesn't have them yet, however. As you overwrite the base character, any mod that is loaded after yours and uses "table.deepcopy(data.raw.character["character"])" won't get the particles either. Perhaps you could add footprints?
@SpaceCat-Chan: I've looked at your code to get the mod name. This mod is now added to the list of known character selector mod that "I, Robot" will recognize. (It won't overwrite the base character if such a mod is found.) In case you want to add support for "I, Robot" to your mod, the character is named "IRobot_character_skin". Also, it would be nice if you'd consider renaming your "hideboar" character, so that it contains the case-insensitive string "skin" somewhere. Finally, I believe you made a mistake with your mod version: Or did you really want this to be version "18.0.1" instead of "0.18.1"? Could easily lead to huge problems with other mods if the dependencies are broken, so you'd better fix that before release. :-D
So, actually we can install this mod on multiplayer server.
and have somewhere a button to selection "male/femal" caracter ?
could you send me the locale file via discord ? @Dae#5125
So, actually we can install this mod on multiplayer server.
and have somewhere a button to selection "male/femal" caracter ?
You will only get the GUI if at least 2 selectable characters are found. There's no option "male/female" because there's no way to know
what a character would actually look like. Instead, you get a list of localized character names (see GUI at the top left of the screenshot
-- if you open it in a new tab, it should be easier to see).
could you send me the locale file via discord ? @Dae#5125
Sorry, I'm not on discord, but you could PM me on the forum if you've got an account there. Anyway, the locale file is quite small, so I'll post its contents here:
[mod-name]
#~ minime=More accurate player size compared to vehicles
[mod-description]
minime=The player stands like a giant near the vehicles. Now you can adjust the size of your character -- and if you use other mods that provide different characters, you can even change your appearance whenever you want with just the click of a button!
[mod-setting-name]
minime_character-size=Character size (in percent)
[mod-setting-description]
minime_character-size=10: tiny\n100: Normal\n500: HUGE\n(Default: 70)
; New strings start here!
#~ If there are several characters available, we rename the default character.
[minime-misc]
base-character=Default character
[minime-GUI]
gui-name=Appearance
gui-name-tooltip=[minime] Choose your character!
toggle-button=Appearance
disabled-button-tooltip=Use the green button to change your character!
disabled-button-tooltip-plural=Use one of the green buttons to change your character!
@Pi-C
could you make a settings.lua in I, Robot with:
if(mods["CharSelect"]) then
table.insert(data.raw["string-setting"]["Selected-Character"].allowed_values, "IRobot_character_skin")
end
in it?
and add
[string-mod-setting]
Selected-Character-IRobot_character_skin=I, Robot
to its locale?
@SpaceCat-Chan: > @Pi-C
could you make a settings.lua in I, Robot with:
Do you really need this in settings.lua? In that case, I'd also have to add a dependency on your mod in order to make sure that data.raw["string-setting"]["Selected-Character"] already exists. Otherwise, I'd rather add that code to settings-update.lua. I've had a problem with another mod recently because of a complicated dependency circle where it really wasn't obvious that things could break (like A-->B-->C-->D-->A).
[string-mod-setting]
Selected-Character-IRobot_character_skin=I, Robot
to its locale?
Sure!
[mod-description]
minime = Le joueur se tient comme un géant près des véhicules. Maintenant, vous pouvez ajuster la taille de votre personnage - et si vous utilisez d'autres mods qui fournissent des caractères différents, vous pouvez même changer votre apparence quand vous le souhaitez en un seul clic !
[mod-setting-name]
minime_character-size = Taille des caractères (en pourcentage)
[mod-setting-description]
minime_character-size = 10: minuscule \ n100: Normal \ n500: ÉNORME \ n (par défaut: 70)
; Les nouvelles chaînes commencent ici !
[minime-misc]
base-character = Personnage par défaut
[minime-GUI]
gui-name = Apparence
gui-name-tooltip = [minime] Choisissez votre personnage !
toggle-button = Apparence
disabled-button-tooltip = Utilisez le bouton vert pour changer votre personnage !
disabled-button-tooltip-plural = Utilisez l'un des boutons verts pour changer votre personnage !
discord factorio are pretty cool and helpfull for mods.
try it ;)
if i understand, you mod chang just the size of the caracter.
could you add somes "male/femal" skin in same time ?
Thanks for the translation, I'll include it in the next release!
if i understand, you mod chang just the size of the caracter.
could you add somes "male/femal" skin in same time ?
The mod will scale any character it finds in data-updates.lua, so if mods like "Gear Girl Character" add a new character, it will be scaled just the same way as the vanilla character. What happens next is up to the other mods. If all mods decide to overwrite the main character, only the last character will remain in the game. If different characters exist once a game is started or loaded, you will get a GUI where you can change your character. So, in a multiplayer game, it would be possible that different players use different skins.
I won't provide characters myself. First, I'm not talented enough to come up with new graphics/animations. Replicating the characters other mods have made is a bad idea: The character selector is a convenient feature, but basically it's an add-on, the main purpose of "minime" still is to make your character smaller. If I was to include other characters (with all the graphics), this would increase the mod size way too much. Also, I'd have to keep track of changes the other mods make to their characters. The way it works now (provide an interface to what already exists) is way better because the character-modders retain full control over their graphics (almost, because I scale them) and I can keep my mod much smaller.
why do you don't make a stand alone mod, with other good idea ?
@Fr_Dae:
[minime-misc]
base-character = caractère par défaut
I don't know much French, but shouldn't "caractère" be Capitalized? It's meant to be displayed as a name, so at least in English and German I would use a Capital letter at the start.
why do you don't make a stand alone mod, with other good idea ?
I already have too many mods that still need updates and fixes, I've got "minime" rather by chance. :-)
@Fr_Dae: Could you also translate this new string, please?
remove-character-button-warning=WARNING: Your current character has become unselectable. If you change your appearance, you won't be able to use your current character (__1__) unless it is activated again by another mod!\n(If you do change your character, all inventories and settings will be saved and restored once __1__ becomes available again.)
Pretty long, but it's about a pretty serious decision, so that seems warranted. Anyway, my next release (some bugfixes, some compatibility changes, and some polishing) is almost ready, so I guess I could upload whenever your translation is done. :-)
Also, I feel a bit bad about abusing the Gear Girl board for discussing minime development. Perhaps we should move over there …
remove-character-button-warning = AVERTISSEMENT: Votre personnage actuel est devenu non sélectionnable. \n
Si vous modifiez votre apparence, vous ne pourrez pas utiliser votre personnage actuel (1) à moins qu'il ne soit à nouveau activé par un autre mod ! \n (Si vous modifiez votre personnage, tous les inventaires et paramètres seront enregistrés et restaurés, une fois 1 redevient disponible.)
@Fr_Dae: Merci beaucoup ! I've already uploaded the new version with your translation. (Sorry for not replying any sooner, I thought I'd done that but didn't realize that my reply never made it because of an expired token…)
Now people have requested other options (e.g. disabling the character selector completely if they don't care about using extra characters). Would you mind translating some more strings? I'll put them up here later on, so we don't have to abuse this thread any longer. :-)
ok
Just updated "minime" again: some bugfixes, some new options. Please give it a try! (There's also a new update for Factorio 0.17, alas without character selector …)
And another update, for better performance. :-)
Hey! I just wanted to bump this, I recently installed the minime mod on my multiplayer server to give users the ability to select whatever gender they want (as well as no gender with the robot) and was disappointed that Gear Girl seems to still be overwriting the default character rather than using the method @Pi-C suggested to first create the character separately and then only overwrite the default if minime et al aren't installed.
I'm also hoping for something like this to be implemented. From what I read and understood, it is possible to have it implemented.
From what I read and understood, it is possible to have it implemented.
You can also test it live with I, Robot. I've "inherited" that mod and made it to work as a kind of show-case for minime, using the method described above in order to work either as a stand-alone mod or together with a character selector mod. Naturally, it will give you just a robot character, not Gear Girl! But it's something you can actually try out and don't have just to read about. :-D
Oh, and of course minime and Gear Girl Character can be used together even now! If Gear Girl is the only character in the game, it will be scaled to the values you've set in minime's startup options just like the default character, and if you add "I, Robot" as well, you'll be able to switch between "Default character" (which then actually uses the Gear Girl character) and the robot -- only the default character from the vanilla game will not be available for selection because it has been overwritten.
I appeared to have managed to modify the Gear Girl Character mod in accordance to @Pi-C's recommendations (not familiar with lua, but I just did a ton of cross-referencing with I, Robot), and it does appear to work with minime properly as well. I don't feel comfortable sharing it without @SleepyEngi's permission, however.
I appeared to have managed to modify the Gear Girl Character mod in accordance to @Pi-C's recommendations (not familiar with lua, but I just did a ton of cross-referencing with I, Robot), and it does appear to work with minime properly as well. I don't feel comfortable sharing it without @SleepyEngi's permission, however.
You have my permission I suppose @beewyka819
I appeared to have managed to modify the Gear Girl Character mod in accordance to @Pi-C's recommendations (not familiar with lua, but I just did a ton of cross-referencing with I, Robot), and it does appear to work with minime properly as well. I don't feel comfortable sharing it without @SleepyEngi's permission, however.
You have my permission I suppose @beewyka819
@SleepyEngi: I don't want to spoil anybody's fun here, and I certainly don't want to discourage anyone from releasing a mod, but this would mean that there are 4 mods around (yours, RitnCharacters, the mod by SpaceCat-Chan which is available on GitHub, and beewyka819's mod) that contain all of your character assets. Each of these mods will have a size of about 35MB to 40MB because they must contain all the graphics and animations. Even worse, if you'd ever decide to change anything in your character, these changes would have to be implemented in all other mods as well.
This would also raise questions for maintainers of character selector mods (RitnCharacters, SpaceCat-Chan's mod, and minime so far) -- should they add conflicts with some mods (because, for example, the same character exists under two different names)? Should the different character mods conflict with each other?
I still believe it would be better to make the fix in the original mod. If you don't feel like doing this yourself, perhaps beewyka819 would cooperate (the code seems to be in place already, so why not use it and give beewyka819 credit for the changes?). Otherwise, if nobody else wants to step in, I'd also be willing to add the code myself and send you the changed files. :-)
@Pi-C If you can help me with that then I could implement it into my mod and credit you then, that would be very helpful
@Pi-C If you can help me with that then I could implement it into my mod and credit you then, that would be very helpful
I've just finished:
(Sorry for the bad quality! I've run 3 instances of Factorio during testing, and that wouldn't have worked with HR graphics. Even this way, the computer slowed down to a crawl after the third player joined …)
According to README.txt, you're on the forum, but I didn't find you there. How can I get the code to you? I'm not on Discord …
Hm, you could message me on reddit - I'm /u/not_dipper_pines , or you could add me on steam, my steam id is 191919333 so you can add me there
the reason my mod has the girl character assets is because i needed something to test with and my mod uses opt-in to figure out which characters are allowed to swap between, so i had no way to actually test it without doing that
currently i have no idea if i should release my mod because minime seems to already do a good job og handeling things and i don't want multiple mods on the mod portal that all acomplish the same thing
the reason my mod has the girl character assets is because i needed something to test with and my mod uses opt-in to figure out which characters are allowed to swap between, so i had no way to actually test it without doing that
Agreed. That's why my original proposal that GearGirlCharacter should not use stand-alone mod (i.e., replace the default character) right from the start, but wait and see if any character selector mods are available.
currently i have no idea if i should release my mod because minime seems to already do a good job og handeling things and
Please understand that I don't want to prevent you from releasing your mod -- I believe I've made that clear in this thread and by adding compatibility with your mod to minime and my take at the Gear Girl code. But thank you for the compliment on minime! :-)
i don't want multiple mods on the mod portal that all acomplish the same thing
My issue was that several mods shipping the same huge set of graphics isn't optimal (waiting for downloads to finish when a mod gets updated can become tedious). If you changed your mod from recreating the character to using the existing one, you could shrink it to <3% of its current size; having two similar but small mods isn't that much of a problem, in my opinion.
Also, I believe that the mods are different enough to be able to co-exist. There may be players who don't care about minime's scaling (the core feature) at all, so they would fare better with using your mod!
i do have an idea about how to improve compatibility between our mods if i was to release mine.
your mod could listen to the mod_setting_changed event and change your UI accordingly, and your mod could notify mine about the character being changed and my mod could change it's settings accordingly, plus your mod can check my mods mod-settings to get extra characters in your UI
i do have an idea about how to improve compatibility between our mods if i was to release mine.
your mod could listen to the mod_setting_changed event and change your UI accordingly, and your mod could notify mine about the character being changed and my mod could change it's settings accordingly,
I thought I had that in already. Perhaps confusing directories again and working on the wrong version? I'll add that!
plus your mod can check my mods mod-settings to get extra characters in your UI
That's a very good idea, thanks! :-)
your mod could listen to the mod_setting_changed event and change your UI accordingly,
Added, although I'm not sure if this will work correctly. It depends on who will be finished first: Will your mod have removed the old character already when minime can react to the event? It may be safer if you ask minime explicitly to make a backup of the existing character, and tell it later that you're finished with exchanging characters. I already have a remote interface in place that supports this:
-- Use this right *before* you exchange a character, so I can store whatever data I need to store
if remote.interfaces["minime"] then
remote.call('minime', 'make_character_backup', player)
-- player: player.index or player entity
end
-- Use this *after* you've exchanged the character, so that I can update the player's GUI
if remote.interfaces["minime"] then
remote.call('minime', 'player_changed_character', player)
-- player: player.index or player entity
end
and your mod could notify mine about the character being changed and my mod could change it's settings accordingly,
How? Basically, I need to push the data to you. This could be done by defining and raising an event that you'd have to listen to -- which would be versatile because other mods could listen to it as well. The other way is that you made an interface yourself, so that I could call your functions when something has changed. Your choice! :-)
plus your mod can check my mods mod-settings to get extra characters in your UI
Done! I query game.get_filtered_mod_setting_prototypes and pull the character names from allowed_values of your setting on initializing my list. Unfortunately, you can't add characters from my list that way because it's compiled on the fly, not defined in settings -- and you can't add settings in the control stage (game.get_filtered_mod_setting_prototypes is read-only). Adding a function to my interface to get my character list could be useful for other mods, though …
i have made my mod make use of the remote interface, and i think it would be best if your mod defines an event so other mods can listen for character changed events, my mod should probably also do that.
i have made my mod make use of the remote interface,
Thanks! By the way, I've noticed last night that you don't really raise an event when you create a new character. The method is surface.create_entity, but the raise flag is still "raise_built", not "raise_create"…
and i think it would be best if your mod defines an event so other mods can listen for character changed events, my mod should probably also do that.
Not quite as straightforward like it may seem. I can generate a new, unique event ID with script,generate_event_name() -- but you wouldn't know that ID (it won't be mapped in defines.events). So I guess I'd have to generate events and add a function to the interface returning the event IDs so you could register your event handlers by calling that function. Or is there an easier way?
that is the easiest way to do it without additional dependencies
Since this seems to be the place where character sprite interaction is beaing discussed:
Given that Gear Girl and MiniMe are being used, how would I get access to the vanilla character sprites in the data stage of another mod?
Given that Gear Girl and MiniMe are being used, how would I get access to the vanilla character sprites in the data stage of another mod?
With the Gear Girl Character mod as it's currently available on the mod portal, there's no way to guarantee that the vanilla character will still exist by the time your mod is loaded unless it has a name that is sorted before "GirlCharacter" (the internal mod name). You would then have access to it from data.lua, where you could use something like
local default_char = table.deepcopy(data.raw.character["character"])
to make a local copy of it. The sprites themselves are still available because the graphics can't be deleted from the game by a mod (GearGirl just changes the default character to use different sprites).
If such changes as I suggested above are implemented, you'd have guaranteed access to the unchanged data.raw.character["character"] from data.lua and data-updates.lua regardless of what you call your mod. IFF minime (or another character selector mod Gear Girl knows about) is also active, the default character would also still be available during data-final-fixes.lua (and during the control stage) because Gear Girl wouldn't change the default character at all.
Basically, Gear Girl would look for minime or any other character selector mods in data-final-fixes.lua. If at least one of these mods was active, it wouldn't overwrite the default character. Character selector mods could add themselves to the list of known mods in data.lua or data-updates.lua like this:
-- The following line is only necessary if you register your mod in data.lua
GEAR_GIRL_keep_default_character = GEAR_GIRL_keep_default_character or {}
-- mods["NAME_OF_YOUR_MOD"] must be >= "VERSION", or your mod will be ignored
-- (minime didn't have a character selector before version "0.0.14", so it would be useless in earlier versions)
GEAR_GIRL_keep_default_character["NAME_OF_YOUR_MOD"] = "VERSION"
(Coming to think of it, the version check could be improved so that other conditions than ">=" are accepted as well.)
I've uploaded an implementation of this almost a week ago here, so you could check out the code. However, it's up to @SleepyEngi to apply the changes, and I can't tell if s/he will use my code as it is, or in some changed form, or not at all. We'll have to wait for the next update to Gear Girl before we can know anything for sure. :-)
Cheers.
I obviously don't understand how to manipulate the load order by mod name. Named my mod "A-[...]" and it still didn't work. Put an optional dependency in my local copy of gear girl and it worked perfectly. :/
Well. enforcing loading order by mod name has never been really reliably -- dependencies come first, alphabetic order is considered after that (see here). A mod name starting with "A" will give you at least a chance that your mod is loaded first, but dependencies (even of completely unrelated mods you never heard about) could still mess up everything. Factorio's dependency system is rather basic. Asking other mods to wait until you mod has been loaded, or telling them that your mod provides the same function as another mod is impossible.
Has anyone ever tried getting the devs to add a "reverse dependency" to the mod info.json file format?
Just something to say "load me before these" would go a long way to solving so many mod interation problems, and shouldn't be hard to implement - a pre-process pass that slaps extra dependecies onto the listed mods would do the job.
@ SleepyEngi: In the mean time, I'd like to request that this mod: (https://mods.factorio.com/mod/A_Total_Automization_Illy_Varient) gets added to the optional dependency list for gear girl.
Is there any chance @SleepyEngi you implemented @Pi-C's suggestions for compatibility for the two mods? I know it's been 2 months since then, but I just thought I'd ask since I just found both of your mods and was very interested in the two!
Has anyone ever tried getting the devs to add a "reverse dependency" to the mod info.json file format?
There are various dead threads about adding this or that to the dependency system to make it more versatile. At least one about inversing load order: https://forums.factorio.com/viewtopic.php?f=28&t=70116
My impression is that they just want to keep it simple.
I've implemented Pi-C's changes, sorry I haven't been around, real life stuff has kept me off Factorio for a while.
Thanks, this seems to work now! I haven't updated minime for Factorio 1.1 yet, but I'm currently working on it and things seem to go smoothly now. :-)
Pi-c please read your mail bro
Hi
This mod is something I've wanted and asked for a long time. See https://forums.factorio.com/viewtopic.php?p=298907#p298907
For me, the avatar is something about my persona and even if I enjoy the game well enough to forsee that, it is still nagging me. I would most like to have a pop-princess character for Factorio, cute and cool at the same time! <3 <3
Actually, I've been playing around with Art's Girl Clothes mod, an asian princess, (https://mods.factorio.com/mod/artsGirlClothing) but to switch to a female character one need to change the armor used. That in turn have made me modify and duplicate the recipe for all armors used in a specific modpack. It do work for me, but I won't even think about uploading such a quirky approach. :(
You are using better approaches that should work in all cases. I think it maybe could collide with armor graphic mods in the future, but if that happen, there may be a way to combine or exclude that for happening?
Moreover, I've also discovered https://mods.factorio.com/mod/NepgearReNepped which also add a character but overwrites Gear Girl/Guy, so either she or Gear Guy could currently coexist with Nepgear in the same game as for now. More characters is always welcome since it should at least have been some chargen in the base game, at least what my opinion is.
Thank you for getting together and begun a serious attempt to make a simple switch that works in most cases. I can think about getting involved, but then you need to have patience for me getting off Factorio for many months sometimes.
Actually form a technical standpoint the armor approach is a quite interesting. Far less voodoo than has to be done to swap out an existing character for another. Has it's own issues though. Doesn't work when no armor is equipped. And also what happens i.e. when you're wearing a space-suit? etc.
Yes, it is indeed interesting. For example SE could implement a graphic with the character in the space suit when one wears the armor. That could make the game more elegant.
But... by design, it's not an overlay so it replaces the graphic fully, and as I understand the situation - needs to be implemented as a duplicate for every armor for every character to work fully. That would not work well in the long run that way, as the number of graphics needed increases with the square of all possible combinations between armors and characters. Therefore, a more elegant solution is needed if one wants to combine the two ways of implementing a character in a standardized way.
For example, there could be some predefined Themes of a character included in the character mods, i.e. Gear Girl in a spacesuit, Gear Girl in an armor, Gear Girl ... - then some mods which implements armor with graphics could try if there is a Theme with the chosen character and if not, fall back to the standard version of that character or, have an own designated fallback replacement. If someone implements a new mod with space theme and wants her in a space suit, they could just test the same thing and needs not to have extra graphics or duplicate recipes for their mods.
It is worth to mention there is already a theme who needs extra graphics in the base mod - when the character is shooting (he is running with a gun).
As for when I started using Art's mod, if she shot at something, she became Gear Guy for a couple of seconds. I fixed that so I don't know if that are changed in the original mod. (She still has no gun though because I didn't have the graphics). In my remake, she also gets smaller due to the graphics limitation is different for the shooting theme, another issue worth to mention. She is probably too big in the default case.
The armor approach have issues too, if the character dies, the corpse became Gear Guy and not what was last worn. May relate to the fact no armor is worn then. This mod does better, when Gear Girl dies, the corpse is Gear Girl's.
Also the more obvious issues; if someone uses armor to have another appearance for their character, one must make an exclusive armor for that before zhe can transform. The different armors are not interchangeable between players playing as other characters too.
So, the conclusion is that both cases have it's own pros and cons. For just changing the appearance of your character, I think Gear Girl's approach + a char select is better suited.
pi-c ? could you reply t my email ? x)
So for lack of any new engine features I've published my skin swapping mod based on the create_entity character replacement approach. https://mods.factorio.com/mod/eradicators-character-additions
I've finally updated "minime" (now: "miniMAXIme") for Factorio 1.1. Check it out and have fun with it! :-)
Hello PI-c Welcome back :)
can I send you an email soon? I would like to hear from you