Currently Online

Latest Posts

Topic: Blender Python 3.x scripts

feh
Avatar
Topic Opener
Joined: 2021-04-19, 09:26
Posts: 8
Ranking
Pry about Widelands
Posted at: 2021-04-28, 19:48

Good evening!

Are by chance the Python 3.x scripts mentioned on the GraphicsDevelopment page implemented yet? As the text notes blender beta version 2.59 as new, it seems a bit outdated (2011?). Or does the added update about 'the scripts' working in blender 2.76b imply the continued use of Python 2? 

If Python 3.x is indeed implemented, I'll have to search further, as to why nothing happens when I want to run those scripts (e.g. innerWorker.py) in the empty_worker_template. If it's still Python 2, that's most likely the reason.

Blender version 2.92 on Linux Mint.


Top Quote
Nordfriese
Avatar
Joined: 2017-01-17, 17:07
Posts: 1949
OS: Debian Testing
Version: Latest master
Ranking
One Elder of Players
Location: 0x55555d3a34c0
Posted at: 2021-04-28, 22:20

Hi feh and welcome to the forums face-smile.png

As far as I know none of the few active graphic developers have been using these scripts for many years, so they are indeed very outdated. Perhaps they work with the exact blender+python versions mentioned in the wiki, but any other versions… unlikely.

That wiki page is also not being kept up to date. Everyone actually uses their own individual workflow which is not documented anywhere. For example I do the work of rotating, masking etc in Blender manually and use the Java tool in graphics/tools/ to handle scaling and spritesheet generation. Those python scripts were used by the designers of most of the older models, who are not active any more.

So essentially there is no reliable standard way of processing Blender models into game-usable images. If I may ask what you're intending to use the scripts for perhaps I can help further face-smile.png


Top Quote
feh
Avatar
Topic Opener
Joined: 2021-04-19, 09:26
Posts: 8
Ranking
Pry about Widelands
Posted at: 2021-04-29, 08:24

Thanks Nordfriese face-smile.png
I wanted to use them to process Blender models into game-useable images in a reliable and standardised fashion. face-grin.png But worrying about the scripts - if I had to use them and couldn't get them to work - kept me from modelling. So I had to ask.

Even though it would have been nice to simply push a button and instantly have all needed pictures, yours is actually (one of) the answers I hoped for.
So there's also no need to use the templates, I take it? Camera and lighting are positioned last to somewhat resemble the current in-game graphics?


Top Quote
Nordfriese
Avatar
Joined: 2017-01-17, 17:07
Posts: 1949
OS: Debian Testing
Version: Latest master
Ranking
One Elder of Players
Location: 0x55555d3a34c0
Posted at: 2021-04-29, 10:52

I'd still recommend using the templates because they provide the recommended light and shadow directions and camera position. Most of our graphics use the settings found in the template files. (Some don't, e.g. the standing stones, resulting in mixed shadow directions in the game.)
But you can of course create a new model without the templates and arrange all of those freely if you prefer it – even at 4× zoom, the small scale of the in-game graphics means that smaller deviations usually won't be visible in the result.


Top Quote