Wolf3d Haven Forum

Please log in or register. Smile
Wolf3d Haven Forum

A friendly Wolfenstein 3D community, about Wolfenstein 3D, the game that gave birth to first person shooters...


    Wolf4sdl starry sky and ceiling tutorials?

    Share

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 11:47 am

    Hi all, Very Happy

    Decided to join up on here today. I have been reading through code tutorials for the starry sky and also floor/ceiling textures for wolf3d. The problem is, with the wolf4sdl source code it is a little different from the wolf3d source code id released and the tuts do not work for wolf4sdl.

    Can someone point me to any wolf4sdl tutorials to be able to do these 2 things? Id like to try them out on the stock games and see what they are like. I already activated the code for it in version.h but i know you have to do more than that to get it to work.

    Thanks for any help, it is much appreciated. Cool

    Officer-Michael John
    Seasoned Wolfer
    Seasoned Wolfer

    Male
    Number of posts : 332
    Age : 19
    Hobbie : Video and Wolf 3D mode making
    Registration date : 2014-08-04

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Officer-Michael John on Sat Jan 23, 2016 12:57 pm

    Hi! You adding on Wolf 3D mod SDL a WL_FLOORCEILING.CPP and WL_ATMOS.CPP file and you use Rebuild all because then only in good working.
    And you enabling in ChaosEdit a 3rd plane and a Feature flags.

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 1:09 pm

    Thanks for the reply john. I simply want to try out the 2 different mods on wolf3d and spear. Rebuild all does not work, the source code tutorials are for the Wolf3d source, the source for wolf4sdl is a little different so the tuts do not work for wolf4sdl.I already activated the code in version.h and recompiled, but that does nothing when you play the game.

    I just want to try these out on the original wolf and spear of destiny. I tried this out in chaos edit but do not know how to do it. Its not very user friendly. I thought you could use code tutorials for the starry sky and another tut for floor and ceiling.

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sat Jan 23, 2016 1:53 pm

    Actually, those two features are already completely coded on Wolf4SDL. Aside from enabling them on version, which I suppose you had no problems with, you have to tell the game which of them and how they should appear on the game. I'll try not to complicate your life too much. It's basically like this:

    -For starry sky, you place an wall with id 1 on the top right tile (127,0) of the map.
    -For textured floors/ceilings, you have to use the third plane. It might sound a bit weird, but that one value on the third plane defines both the ceiling and the floor textures. ChaosEdit doesn't let you edit the two halves of the value (one for ceiling, one for floor) separately, but WDC does. I'm not sure if HWE has this feature or not. If you try this on WDC, you can choose on the "Map Tools" menu
    the options "High byte mode" and "Low byte mode", which let you edit them separately. It's better if you experiment with it a little, I suppose.

    I can give you a more in-depth explanation of those features should you need one. I just tried to make it simple for now to make things go smooth. Cool

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 1:59 pm

    @Mega Luigi wrote:Actually, those two features are already completely coded on Wolf4SDL. Aside from enabling them on version, which I suppose you had no problems with, you have to tell the game which of them and how they should appear on the game. I'll try not to complicate your life too much. It's basically like this:

    -For starry sky, you place an wall with id 1 on the top right tile (127,0) of the map.
    -For textured floors/ceilings, you have to use the third plane. It might sound a bit weird, but that one value on the third plane defines both the ceiling and the floor textures. ChaosEdit doesn't let you edit the two halves of the value (one for ceiling, one for floor) separately, but WDC does. I'm not sure if HWE has this feature or not. If you try this on WDC, you can choose on the "Map Tools" menu
    the options "High byte mode" and "Low byte mode", which let you edit them separately. It's better if you experiment with it a little, I suppose.

    I can give you a more in-depth explanation of those features should you need one. I just tried to make it simple for now to make things go smooth. Cool

    Thank you for the response. Very Happy So ill start with starry sky first. Let's say i want to enable it for regular wolfenstein when i compile the exe for it, where and what do i use to place the wall with id 1 at? Yes, ive already activated it in version.h for wolf4sdl but i know theres more to it than just that.

    Yes i am a complete noob when it comes to this so sorry about that lol. If you do not mind giving me an in depth answer for starry sky im all ears and would appreciate any of your input. Smile

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sat Jan 23, 2016 2:16 pm

    Ah, just one thing, I mentioned the top right tile as being (127,0). Sorry about that, it is actually (63,0), I'm used to working with 128x128 maps and I confused myself.

    No problem on being a noob, everyone has been there already on some point Smile.

    When I said about placing the wall, I meant you should place it in the map itself, using a map editor, like WDC, ChaosEdit, or any editor of your preference that can edit maps. Once you have enabled those features compiled the code, the game will activate the starry sky if it detects the wall with id 1, which happens to be "Grey Brick 1" on the top right tile, which is the tile with coordinates x=63, y=0. Similarly, that same tile is used if you wanted to activate rain or snow.

    Each of these features has an specific tile which controls if it will be activated on a specific map or not. In the case of starry sky, that is the tile (63,0), and what controls if it is activated or not is the wall with the id 1. Similarly, for rain, the wall id would be 16, and for snow, 32.

    Suppose you wanted starry sky AND rain. You can think of it like if you were summing the two values: 1 + 16 = 17.
    So, you would place a wall with id 17 on that tile, which happens to be "Red Brick".

    Lemme know if you succeed on that.

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 2:35 pm

    weird. i activated starry sky and now the compiler throws an error saying:

    startj : undeclared identifier in wl_atmos.cpp pale


    in this block of code:

    int stopx = 10, starty = 0, stopy = 10;
    i = 0;
    if(xx < 0) i = -xx;
    if(xx > viewwidth - 11) stopx = viewwidth - xx;
    if(yy < 0) startj = -yy;
    if(yy > viewheight - 11) stopy = viewheight - yy;
    for(; i < stopx; i++)
    for(int j = starty; j < stopy; j++)
    vbuf[(yy + j) * vbufPitch + xx + i] = moon[j * 10 + i];
    }

    Guest
    Guest

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Guest on Sat Jan 23, 2016 3:07 pm

    Hi joewolf,

    This Wolf4SDL version by Andy has a lot of fixes/improvements, including the sky thing (copy the link into your browser).

    dl.dropboxusercontent.com/u/7126339/Wolf4SDL1.7e_src.zip

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 3:27 pm

    Hi theperfectdrug!

    Thanks for the link! I have to use the source i have as i am porting this across to another console as well. I would have to re-port everything but i will take a look at it. It makes no sense as i was getting compiles. ALso @luigi, when i opened gamemaps.wl6 in chaos edit there was already a grey brick at the top right corner, when i changed it to red brick it made the pc and console freeze.

    I have to find a way to work around this error. Suspect

    Im going to try a couple more things, but this is crazy. Razz


    EDIT***

    Im not sure what i am doing wrong. I am simply going into chaos edit then putting the wall in the corner that activates the parallax sky. When i save it overwrites my map head file down to 1kb and then messes it up. I have parallax activated and NOTHING still shows up. WTF. cherry Evil or Very Mad

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sat Jan 23, 2016 5:51 pm

    Hmm, that block of code you pasted seem a little weird for me. Do you know what version of Wolf4SDL you're using? I'm afraid you might be using a very old one. Even the one I use which is old doesn't seem like that. Judging by that, I suppose there could be a lot of reasons for that freeze.

    If you find that you're using a old version, you could try to copy the sky routines from the newest version to your own. I won't say you won't have to make some adjustments if you do that, though. Either way, since things seem to be a little unstable, I wouldn't recommend you to put the red brick there (what means you want the sky and rain), but to try only the sky until you get it working. Your problems could also be caused by the rain, right?

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 5:57 pm

    @Mega Luigi wrote:Hmm, that block of code you pasted seem a little weird for me. Do you know what version of Wolf4SDL you're using? I'm afraid you might be using a very old one. Even the one I use which is old doesn't seem like that. Judging by that, I suppose there could be a lot of reasons for that freeze.

    If you find that you're using a old version, you could try to copy the sky routines from the newest version to your own. I won't say you won't have to make some adjustments if you do that, though. Either way, since things seem to be a little unstable, I wouldn't recommend you to put the red brick there (what means you want the sky and rain), but to try only the sky until you get it working. Your problems could also be caused by the rain, right?

    That block of code can be found in the newest version of wolf4sdl here is the code straight from the wolf4sdl svn:

    lol, at this point im just trying to activate stars, nothing else, to use in the regular version of wolf3d. WHen i use chaos edit it also messes up the files when i save and makes everything freeze before it loads.

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sat Jan 23, 2016 6:33 pm

    My bad then, though this shouldn't be complicated to do. It should be just as simple as inserting the wall on that tile. Did you try using another map editor, since you say ChaosEdit messes the files?

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sat Jan 23, 2016 7:10 pm

    no worries man. Smile I tried to post the link but it wont let me post links for 7 days since im new. Ive tried over and over to put the wall into that tile but it always makes the console freeze when i try it out, with the sky activated in the code.

    Half the time it does not seem to save it right unless i am doing something wrong. I tried another editor but it kept crashing.

    EDIT*** Well, i got the starry sky working. Ill call it a night now hahaha. bounce bounce bounce bounce

    Guest
    Guest

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Guest on Sat Jan 23, 2016 8:44 pm

    What a waste. 13 posts and all we get out of it is "it wasn't working but now it is" Laughing

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sun Jan 24, 2016 5:40 am

    hahah sorry, i was tired when i posted that.

    The level editor was fine, in the actual code i did not have the feature flags activated so everytime the game started it was locking up.

    So im going to move to the next tut, getting ceiling and floor textures to work. Smile

    ronwolf1705
    Hardcore Wolfer
    Hardcore Wolfer

    Male
    Number of posts : 1252
    Age : 25
    Registration date : 2007-03-26

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by ronwolf1705 on Sun Jan 24, 2016 5:48 am

    I believe that can also be enabled in VERSION.H




    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sun Jan 24, 2016 7:44 am

    Thanks ro! Ok i got parallax sky working. I forgot to activate cloud sky with it because it was freezing. One more noob question, can we use parallax sky with rain and snow, etc?

    And ill have to get on another editor and figure out the floor/ceiling tiles now as well. some progress is better than none. Smile

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sun Jan 24, 2016 10:06 am

    Good to hear you had some success, at least. Answering your question, yeah, you can do that. Like for the starry sky, parallax sky has specific tiles to control how it will show. In this case, there are two. One to activate it, and one that is the first texture to be used for the parallax sky.

    To activate it, you place the wall with id 2 on the top right tile (63,0). To choose the texture, you place the desired wall on the bottom left tile (0,63). This doesn't include the rain, though.
    To use the rain, like I told you yesterday, you place the wall with id 16 on the top right tile (63,0). Like with the example I gave, you can think of this as a summing operation (although it is not, but that doesn't really matter now, does it?), so, if you want them both, you place the wall with id 16+2 = 18 on the top right tile. Of course you still must place the first texture on the bottom left tile too. Try to see what you can do with it.

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Sun Jan 24, 2016 10:56 am

    Thanks luigi! You have helped me out immensely man! Ill mess with this for a bit and then try out the third plane for floor/ceiling tiles. You say we have to use a different editor than chaos edit for that? Are they in the same locations like at the top right corner?

    Mega Luigi
    Bring em' On!
    Bring em' On!

    Number of posts : 135
    Age : 13
    Registration date : 2012-11-01

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Mega Luigi on Sun Jan 24, 2016 11:15 am

    Glad to know that Smile

    For the floor/ceiling textures, you don't have to use any specific corner tiles. If you want a room to have some texture, you simply go on and fill the room with that texture in the third plane. It's just like you would do to fill the room with any object, except that you are in the third plane. You don't HAVE to use another editor since ChaosEdit can edit the third plane as well. The thing here is that you will insert a single id on the third plane, and that is going to define both floor and ceiling textures (although you can place them separately on the 3d edit). That can be a bit annoying at times. If you want to try it on ChaosEdit, the less complicated way to do is:

    -You enter the 3d edit mode and place the ceiling/floor texture according to your wishes on a single tile
    -Then you go back to the map editor itself, and you should see the third plane "object" that you just placed, and that single object's id represents both the ceiling and floor textures of that single tile you chose.
    -Now you can copy that tile and fill any rooms you wish using the map editor, which is a much faster way than do it all through the 3d edit.

    I don't really like having both ceiling and floor textures on the third plane. For me, it complicates things and also limit the number of textures you can have. If you were to add a fourth plane so that each one had a specific plane (which is not hard to do), you wouldn't be able to use ChaosEdit though, since it has no support for more than three planes.

    stathmk
    Hardcore Wolfer
    Hardcore Wolfer

    Male
    Number of posts : 1403
    Age : 36
    Location : Indiana, United States
    Job : fast food worker & wolfensteingoodies.com webmaster
    Hobbie : old games & young dames
    Registration date : 2008-04-08

    Do you want lightning with that?

    Post by stathmk on Mon Jan 25, 2016 9:41 am

    I know that you are specifically asking for starry sky & ceiling tutorials, but this reminded me of lightning. You can do a search at Diehard Wolfers for lightning:

    http://diehardwolfers.areyep.com/viewtopic.php?t=2142&highlight=lightning
    Adam Biser mentions Ripper's lightning tutorial:
    http://diehardwolfers.areyep.com/viewtopic.php?p=26656&highlight=lightning#26656

    Also, I think that Rise of The Triad has thunder & lightning.

    joewolf80
    Freshmen
    Freshmen

    Number of posts : 11
    Age : 30
    Registration date : 2016-01-23

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by joewolf80 on Mon Jan 25, 2016 6:33 pm

    Thanks luigi and for posting those links stathmk! I will def check out how to do that. I will post progress with the floor and ceiling tiles and the lightning as well. I am def intrigued! Smile

    Sponsored content

    Re: Wolf4sdl starry sky and ceiling tutorials?

    Post by Sponsored content Today at 6:59 pm


      Current date/time is Fri Dec 09, 2016 6:59 pm