Saitama520

Newbie
Jun 16, 2018
76
76
I installed python but its telling me python not found launch unsuccesful
Did you choose the "Add to PATH" option when installing? Nevermind, you didn't. It was there, somewhere. Try reinstalling Python. Edit: Maybe also try restarting.
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
Did you choose the "Add to PATH" option when installing? Nevermind, you didn't. It was there, somewhere. Try reinstalling Python. Edit: Maybe also try restarting.
Restarting did it. So it all compiled. I have a separate folder of AI graphics and pregmod, do I keep it that way? What do I enter into the URL for API URL? Do I need to run compile every time before playing?
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
First, download one of the latest alpha of pregmod. It's not that hard to find. Next, get the Automatic1111 web UI working assuming your system meets the requirements (16 GB RAM, 2 GB+ VRAM, NVidia GPU recommended). which is still valid AFAIK. Alternatively, just install the needed Python version (3.10.6) and download the . Expand the zip where you want, open webui-user.bat and let it run, download and install everything needed. Go to and find a model with an aesthetic you like, photorealistic, anime, cartoon, whatever. Download and put said model in /models/Stable-diffusion. Once the WebUI is done installing and loading, tell it to load whichever model you've picked.

Once the model loading is done, quit and duplicate the webui-user.bat file and rename it; this is the one you will be using with pregmod. Change the commandline arguments to the following, assuming no other arguments are already present:

Save, close, then launch the .bat. Once it's done loading, open pregmod, go to the options and select the AI image generation option. If it's working, you should see the stable diffusion console window start working. The rest of the options are dependent upon your system resources and the model (and aesthetic) you ended up picking so I can't really direct you any further.
How do you tell it to load a model?
 

Arabi1

Member
Donor
Oct 23, 2023
799
1,784
I have a new routine. I drank two cups of tea today to finally install this pregmod, but my head is aching from all the details and now I've decided to do it later. This is the third or fourth time I've said "I'll do it later".

Edit: Somehow I managed to get it to work.
 
Last edited:
  • Haha
Reactions: DarthSion98

DarthSion98

Member
May 31, 2020
386
435
I have a new routine. I drank two cups of tea today to finally install this pregmod, but my head is aching from all the details and now I've decided to do it later. This is the third or fourth time I've said "I'll do it later".

Edit: Somehow I managed to get it to work.
Is it really that hard to install the mod?
I did it once after drinking 5 beers.
 

Arabi1

Member
Donor
Oct 23, 2023
799
1,784
Is it really that hard to install the mod?
I did it once after drinking 5 beers.
I saw the comments talking about AI and compiling and shit when I hadn't even downloaded the game.

So I said fuck it and put them all in the same folder and opened the mod and it worked just like that.

I feel like I'm doing something wrong.
 

Saitama520

Newbie
Jun 16, 2018
76
76
Restarting did it. So it all compiled. I have a separate folder of AI graphics and pregmod, do I keep it that way? What do I enter into the URL for API URL? Do I need to run compile every time before playing?
The webui-user.bat file in the Stable Diffusion WebUI folder is how you will start the AI process running; the AI art generation system is completely separate from pregmod and will be running in the background either generating images upon request or waiting for requests to arrive. Its location on your hard drive in relation to pregmod does not matter; all that matters is whether or not you gave it the commandline arguments as specified earlier that will allow it to hear any generation requests pregmod sends it. Yes, you will need to start the AI system every time before you play pregmod and this is not compiling.
How do you tell it to load a model?
Easiest way is through the webui, located at or whenever the AI system has started up sufficiently.
models.JPG
Click for a drop-down list of the models you have avaliable, click on a model to load it. Whenever the AI system starts it will open the last model you told it to use. If you only have one model then it will default to that model. If you have no models it'll download a model for you (probably SD 1.5). When you see a message like this in the console window it's done loading and ready to go.
done.JPG
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
The webui-user.bat file in the Stable Diffusion WebUI folder is how you will start the AI process running; the AI art generation system is completely separate from pregmod and will be running in the background either generating images upon request or waiting for requests to arrive. Its location on your hard drive in relation to pregmod does not matter; all that matters is whether or not you gave it the commandline arguments as specified earlier that will allow it to hear any generation requests pregmod sends it. Yes, you will need to start the AI system every time before you play pregmod and this is not compiling.

Easiest way is through the webui, located at or whenever the AI system has started up sufficiently.
View attachment 3756992
Click for a drop-down list of the models you have avaliable, click on a model to load it. Whenever the AI system starts it will open the last model you told it to use. If you only have one model then it will default to that model. If you have no models it'll download a model for you (probably SD 1.5). When you see a message like this in the console window it's done loading and ready to go.
View attachment 3757000
Thanks. The visuals help a lot. So the guide on the top says to download 1.4 ai model and gives us a link and tells us to rename it. Step 3 and 4 here

does that mean we need to download another model from somewhere else or is this one of
Those?
 

Saitama520

Newbie
Jun 16, 2018
76
76
Thanks. The visuals help a lot. So the guide on the top says to download 1.4 ai model and gives us a link and tells us to rename it. Step 3 and 4 here

does that mean we need to download another model from somewhere else or is this one of
Those?
You will need a model; which one you go for is entirely up to you. Renaming it/them is optional. The model used will determine the aesthetic of what it generates and every model has different capabilities. The ones suggested on Rentry are not required, though again you will need at least one model for Stable Diffusion/the AI art generation system to work. There's lots of models everywhere and is a pretty decent repository.

Things to keep in mind:
  • The ability to generate NSFW stuff varies greatly between models; some do it at the drop of a hat, others need to be finagled to do so. Given how it will be pregmod generating the prompts and not you, pick a model that's geared towards lewdity if you can.
  • Avoid any and all XL models - I don't know your hardware and setup, you most likely don't know what you're doing with the AI system so let's just not touch that.
  • LoRAs/Lycoris are NOT what you want; they are tiny models designed to do specific things. The models you want are also called checkpoints, have file extension .safetensors and are generally 2-6 GB in size.
  • Do you want anime, cartoon or realistic titties? Models tend to be aimed towards a specific aesthetic, so keep that in mind when choosing one. I can make a few suggestions for anime and realistic models if needed.
  • Slaves in Free Cities can vary greatly in appearance and ethnicity and many models are not very good at differentiating between ethnicities. If that matters to you it's something to be aware of.
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
You will need a model; which one you go for is entirely up to you. Renaming it/them is optional. The model used will determine the aesthetic of what it generates and every model has different capabilities. The ones suggested on Rentry are not required, though again you will need at least one model for Stable Diffusion/the AI art generation system to work. There's lots of models everywhere and is a pretty decent repository.

Things to keep in mind:
  • The ability to generate NSFW stuff varies greatly between models; some do it at the drop of a hat, others need to be finagled to do so. Given how it will be pregmod generating the prompts and not you, pick a model that's geared towards lewdity if you can.
  • Avoid any and all XL models - I don't know your hardware and setup, you most likely don't know what you're doing with the AI system so let's just not touch that.
  • LoRAs/Lycoris are NOT what you want; they are tiny models designed to do specific things. The models you want are also called checkpoints, have file extension .safetensors and are generally 2-6 GB in size.
  • Do you want anime, cartoon or realistic titties? Models tend to be aimed towards a specific aesthetic, so keep that in mind when choosing one. I can make a few suggestions for anime and realistic models if needed.
  • Slaves in Free Cities can vary greatly in appearance and ethnicity and many models are not very good at differentiating between ethnicities. If that matters to you it's something to be aware of.
Awesome. Thanks! I got the AI to work, it opens a and allows me to generate images. When I go into free cities and enter that link into image generation it still remains blank.

I copied the webui-user.bat and added the line set to:

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins *

and

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins

And receive this error in the renamed edited startup file

launch.py: error: argument --cors-allow-origins: expected one argument
Press any key to continue . . .

When I use saitamas line of it gives me this error:
OSError: Cannot find empty port in range: 7860-7860. You can specify a different port by setting the GRADIO_SERVER_PORT environment variable or passing the `server_port` parameter to `launch()`.
Creating model from config: C:\Users\Owner\Downloads\stable-diffusion-webui\repositories\generative-models\configs\inference\sd_xl_base.yaml
C:\Users\Owner\Downloads\stable-diffusion-webui\venv\lib\site-packages\huggingface_hub\file_download.py:1132: FutureWarning: `resume_download` is deprecated and will be removed in version 1.0.0. Downloads always resume when possible. If you want to force a new download, use `force_download=True`.
warnings.warn(


When I wait it comes to:

Applying attention optimization: Doggettx... done.
Model loaded in 162.0s (load weights from disk: 1.2s, create model: 0.8s, apply weights to model: 115.6s, apply half(): 11.0s, apply dtype to VAE: 4.2s, load VAE: 0.3s, load weights from state dict: 0.8s, move model to device: 9.9s, hijack: 12.7s, load textual inversion embeddings: 2.2s, calculate empty prompt: 3.4s).
Press any key to continue . . .


And I press any key and it just closes the window




Whats left to do?
 
Last edited:

Saitama520

Newbie
Jun 16, 2018
76
76
I copied the webui-user.bat and added the line set to:

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins *

and

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins
That command is for ForgeUI which is not what you are using. You are using the Automatic1111 UI. Don't use commands for another environment.
When I use saitamas line of it gives me this error:
What comes to mind is you're already running the AI system thus the port is taken, you have something else on your system taking the port or you did something strange to the arguments in the webui-user.bat file. Double check your arguments.
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
That command is for ForgeUI which is not what you are using. You are using the Automatic1111 UI. Don't use commands for another environment.

What comes to mind is you're already running the AI system thus the port is taken, you have something else on your system taking the port or you did something strange to the arguments in the webui-user.bat file. Double check your arguments.

Hate to ask this since youve done so much, would you mind adding me on discord and helping me figure this out?
Hookeroo, user id 317386926137147403
 
Jan 18, 2021
312
529
I copied the webui-user.bat and added the line set to:

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins *

and

COMMANDLINE_ARGS=--listen --port=7860 --api --enable-insecure-extension-access --cors-allow-origins

And receive this error in the renamed edited startup file

launch.py: error: argument --cors-allow-origins: expected one argument
The parameter --cors-allow-origins requires one argument. In this case, the argument that you want is * to indicate that the requests to the UI can come from any address. So the * in the first line is mandatory. The second line is incorrect and will always trigger the error that you have reported. Do not use the second line in your batch file.

To reduce the risk of errors, I recommend using an equals sign instead of a space between the parameter and its value, so that it is more obvious that the value is not optional. You should consider ending your command line with --cors-allow-origins=*.
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
The parameter --cors-allow-origins requires one argument. In this case, the argument that you want is * to indicate that the requests to the UI can come from any address. So the * in the first line is mandatory. The second line is incorrect and will always trigger the error that you have reported. Do not use the second line in your batch file.

To reduce the risk of errors, I recommend using an equals sign instead of a space between the parameter and its value, so that it is more obvious that the value is not optional. You should consider ending your command line with --cors-allow-origins=*.
I had someone try to help me trough discord but they couldn’t figure out what the issue was. Maybe it’s my firewall or whatever, he sent me his own file etc but still couldn’t get it to work. The ai generates images on the website but not in game. If anyone knows what the issue could be Lmk
 

IKagamiY

New Member
Mar 25, 2024
3
0
I found this game today, got amazed that there's an AI generator with Pregmod... But today, I am a defeated man.
I just spent the last 5 hours trying to fix the unfixable and.... I should go sleep now. I can start the AI but images will not appear in game. As someone said above, the User.bat file would be the one used but... I can't make it work. Before it was some bs, now it says it cannot download Torch even though the Run.bat already downloaded it. If I try and make the argument via notepad on the User.bat file, this time, the Run.bat will not run. I've tried countless times to clean install Python and webui but nothing works.
Now, if nobody can help me with this, I might just have to forget about this game forever.
Ugh
i need sleep
 

Tataro

Well-Known Member
Mar 27, 2018
1,106
1,620
I found this game today, got amazed that there's an AI generator with Pregmod... But today, I am a defeated man.
I just spent the last 5 hours trying to fix the unfixable and.... I should go sleep now. I can start the AI but images will not appear in game. As someone said above, the User.bat file would be the one used but... I can't make it work. Before it was some bs, now it says it cannot download Torch even though the Run.bat already downloaded it. If I try and make the argument via notepad on the User.bat file, this time, the Run.bat will not run. I've tried countless times to clean install Python and webui but nothing works.
Now, if nobody can help me with this, I might just have to forget about this game forever.
Ugh
i need sleep
Dm me on discord. hookeroo
 

aspar4gus

Active Member
Mar 27, 2019
929
2,326
Too bad his first discovery got ruined by setting up the non-beginner friendly AI setup, the game ran perfectly fine with ol reliable vector paperdoll, i've only tried the webgl once but iirc that one is also easy to setup no need for complicated technical expertise
 

IKagamiY

New Member
Mar 25, 2024
3
0
Dm me on discord. hookeroo
Sent a friend request, name is KishiP(kishiphio) on discord.

Too bad his first discovery got ruined by setting up the non-beginner friendly AI setup, the game ran perfectly fine with ol reliable vector paperdoll, i've only tried the webgl once but iirc that one is also easy to setup no need for complicated technical expertise
Idk, it wasn't supposed to be hard at first, had a guide to follow and all as well directly via Free Cities.... Until nothing worked as prescribed in the guide :HideThePain:
 

IKagamiY

New Member
Mar 25, 2024
3
0
Alright...? It seems to work now?
Just re-did the same thing of putting the argument in the user.bat file that I couldn't launch, same for the run.bat, but today it seems to have worked somehow ? Maybe just restarting and giving it a day worked better than bashing my head against it.
I did not expect the AI to take so much memory though, will have to see if I can do something about that.
 
4.40 star(s) 23 Votes