Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  
gggmork

spam texture to all missing 2 sided lines?

Recommended Posts

I have a map where all the textures look correct at map start, however lots of moving sectors will make HOMs visible later in the map since every line doesn't have a top/bottom texture on its front/back and the moving floors will later make them visible. So do you know of a way to spam a texture to all front/back top/bottoms (but not overwriting current textures, just spamming a texture into all the top/bottom 'blanks').
The easiest way I know to spam textures EVERYWHERE is to select every single 2 sided line and paste a texture to every front/back's top/bottom, but that'll make every line textured the same and overwrite all the current textures.

Share this post


Link to post

OBLIGE appears to do that by default, but that's probably not the sort of solution you're looking for.

Share this post


Link to post

I found a python doom package made by the post hell mascot called omgifol, since I only speak python (like a babbling infant). You'd think it'd be easy to use it to make a SIMPLE loop with one condition in it, something like:

for ALL THE DAMN SIDEDEFS IN THIS MAP, YO:
if upper or lower texture == '-', ie. if its BLANK you STUPID COMPUTER
Then fucking fill it with 'MARBLE1' or some shit dumb ass

But noooooooo, because other people's code is an indecipherable mess of mumbo jumbo even when I supposedly know the language.

Share this post


Link to post

Deepsea had a feature that would actually make the texture name of a invalid texture-less part "missing". So you could just search for the name "missing" to find those; or do a find & replace.

Share this post


Link to post

If you're using Doom Builder you can probably just use the "check for errors" deal, and you can go through the list of missing textures it presents. You might be able to do it with the Find & Replace, and just use "-" for the texture to find? [EDIT] Seems you can do this, but it seems to includes EVERY side that doesn't have a high middle or low texture, regardless of if it is visible or not.

Share this post


Link to post

I'M THE BEST MAYNE, I DEED IT https://www.youtube.com/watch?v=VY-JOD3P_Bw

--
(first rename the folder omg, not omgifol-0.2 (should only have a single omg folder, not double nested omg folders) and put it in python/lib/site packages). Put myTestMap.wad in the same folder as the .py file of the below code, and some_wad.wad will save to that folder too)

import omg

w = omg.WAD(from_file='myTestMap.wad')

e = omg.MapEditor(w.maps['MAP24'])
for s in e.sidedefs:
	if s.tx_up == '-':
		s.tx_up = 'CEMENT9'
	if s.tx_low == '-':
		s.tx_low = 'CEMENT9'

w.maps["MAP24"] = e.to_lumps()

w.to_file('some_wad.wad')


print 'ass'
--

I tried:
print s
and it said s is a 'sidedef object'... there's no sidedef class in all 10 files as far as I could tell, so how did this mysteriously become an object, who knows.
I didn't know what a sidedef 'object' was or how to use it (OOP is a bunch of black boxes where you don't have to know internals my ass).
Luckily I remember you can type
help(s)
and that let me at least know tx_low and tx_up were attributes of this mysteriously apparently nonexisting class.

--
Thanks for the deepsea solution too (didn't try because I don't have it and the above python code worked). I think I tried those doombuilder, search for '-' and fix missing textures etc and didn't do what I wanted.

Share this post


Link to post
Mordeth said:

Deepsea had a feature that would actually make the texture name of a invalid texture-less part "missing". So you could just search for the name "missing" to find those; or do a find & replace.


I think the problem here is that the textures are not missing at the editing stage but become missing when the map runs and platforms move. I know that DeePsea will detect some of those but not all.

However, DeePsea does allow a search and replace for "-" and it allows you to specify upper, middle or lower sidedefs too so you could do a search/replace for all lower textures with "-" and replace them with whatever you wanted to appear there. That would, of course, make most lines in the map have the lower texture on it whether you needed it there or not but it wouldn't matter too much I guess. After doing that you could possibly run the DeePsea "automatic remove extra texture names" error check and that would remove a lot of the unneeded ones but I'm not sure how clever or careful it is and it might remove more than you wanted it to. (Note, that's different to the routine to delete unused textures that are defined in the WAD which is a totally different function.)

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  
×