Announcement

Collapse
No announcement yet.

2d sprites replacing models help

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • 2d sprites replacing models help

    Hello,

    I want to try to build a game out of darkplaces source port. Could be a lifetime project as I don't have a lot of spare time but i've been thinking about it for some years now. My coding skills are pretty bad as i'm more into gfx and sound design. So i'm looking for some help doing the code part.

    I would like to replace models with hd 2d (animated)sprites - (weapons-ennemies-effects-projectiles-items,etc...). I know that some already achieved this like the wolf3d port and Retroblazer. It's the only thing I need for the moment. Beggining with a quake one semi-2D mod for testing purposes, and maybe switching to a total conversion if it's working good.

    For the history, i've been using some mapping tools in the past, hammer and radiant. And did lots of textures/skins back in the day of [email protected], for friends and our local lan parties. But i focused on audio the past ten years..

    Dreaming of an old school esoteric/dark/ambient/maze/bloody shooter.

    sorry for my not-good-english and thanks for reading.

    Ayyynn

  • #2
    Hello ayyynn,

    sprites are handled almost identical like models.
    - the animation
    - the textures/skins handling
    - the precaching and spawning
    - the movement
    - ...

    There are many mods that are using sprites available (also with source code included) for you to read and maybe learn from. Even original Quake has 2 or 3 examples about Sprites and how they are handled.

    What specific question do you have ? I cannot see it when reading your post (but my english is poor).

    Best wishes,
    Seven

    Comment


    • #3
      Both of you have some awesome english... I feel like I'm in the twilight zone. Y'all (at least) write better english than a bunch of people that "know" ONLY english.

      sorry my reply is off topic.
      http://www.nextgenquake.com

      Comment


      • #4
        Yeah Seven, your english is anything but poor! I wouldn't have figured out you weren't a native english speaker if it weren't for your repeated use of "comparism" instead of comparison. Ayyynn, you're not bad at all either. Good luck with your project. Something along the lines of Heretic/Hexen?
        ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
        ♪ What a glorious feelin' I'm haaaaaaappy again ♪

        Comment


        • #5


          Thanks for you replies!

          So i'm going to start replacing weapon view models with sprites. It seems that I cannot just replace the line of code that points to the v_weapon.mdl file with a v_weapon.spr file and precache_model the .spr file.

          i'm having a hard time finding the documentation about sprites and qc + i know that there are some differences by using darkplaces engine.

          If you have any reference of an open source quake mod using sprites, i would be pleased. The wolf3d ports seems to use *.mdl files made of a plane square and a texture attached to it. I couldn't find other quake one mods using sprites as weapon models.

          I'll continue my research and post advancement here!

          Originally posted by bfg666 View Post
          Something along the lines of Heretic/Hexen?
          more close to 1997 Blood
          Last edited by ayyynn; 09-25-2016, 09:49 AM.

          Comment


          • #6
            About the technical side of things, maybe you should go at Func_Msgboard. There's plenty of knowledgeable modders and programmers over there that are willing to help. I remember specifically a discussion that took place not so long ago about including sprite trees in Quake.
            Originally posted by ayyynn View Post
            more close to 1997 Blood
            Cool! Looking forward to it.
            ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
            ♪ What a glorious feelin' I'm haaaaaaappy again ♪

            Comment


            • #7
              Thanks, i found the thread on func_msgboard!

              I put this here as a bookmark

              http://www.celephais.net/board/view_...7889&end=27913

              https://www.youtube.com/watch?v=yoSl...ature=youtu.be
              http://quakeone.com/forums/quake-hel...ed-models.html

              Comment


              • #8
                You're welcome.
                ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
                ♪ What a glorious feelin' I'm haaaaaaappy again ♪

                Comment


                • #9
                  Originally posted by bfg666 View Post
                  About the technical side of things, maybe you should go at Func_Msgboard. There's plenty of knowledgeable modders and programmers over there that are willing to help. I remember specifically a discussion that took place not so long ago about including sprite trees in Quake.
                  Programers/Coders & Modders are likely to hang out at insideqc.com more than at func_msgboard. Well, except Spike and Baker; they seem to do their work everywhere.



                  Originally posted by ayyynn View Post
                  I do not know if alpha masked models really help you in your goal to use sprites in Quake, especially as view weapon replacements.
                  As I said, simple sprite trees or any other map entity can be placed just like regular 3D models. There is not much of a difference.



                  Originally posted by ayyynn View Post


                  Thanks for you replies!

                  So i'm going to start replacing weapon view models with sprites. It seems that I cannot just replace the line of code that points to the v_weapon.mdl file with a v_weapon.spr file and precache_model the .spr file.

                  i'm having a hard time finding the documentation about sprites and qc + i know that there are some differences by using darkplaces engine.

                  If you have any reference of an open source quake mod using sprites, i would be pleased. The wolf3d ports seems to use *.mdl files made of a plane square and a texture attached to it. I couldn't find other quake one mods using sprites as weapon models.

                  I'll continue my research and post advancement here!
                  I do not know of any Quake mod that uses sprites as view weapons except Retroblazer. But I do know mods that use animated sprites, which can be replaced 100% by models and vice versa. The small mod compilation for example.
                  You can open its source and look at these projectiles which are sprites:
                  - Reiver ghosts
                  - Reiver hands
                  - sprite flames
                  - yakman projectiles
                  - necromancer summoning effect

                  Going thorugh the code for the sprites will show you how they are spawned, animated, moved, controlled and touched. You will see that everything works just like you would do it with models !



                  Regarding view weapon sprites:
                  I quickly made a test with original Quakes explosion sprite: s_explod.spr
                  Important for you to know is, that Darkplaces (as well as several other engines) can handle sprites when you rename them from lets say s_explod.spr to v_shot.mdl automagically !

                  So, what I did was:
                  I just renamed a copy from s_explod.spr to v_shot.mdl and placed it into the mods /progs folder.
                  I only had to adjust its origin coordinate a little bit forward that you can actually see it in-game (as you know view weapon have a specific offset that they appear wher they appear in-game).


                  This is how it looks like when I shoot my shotgun in-game.
                  I didnt want to make a video clip. A gif should be enough:



                  As you can see, the sprite is acting like a model.
                  Important to know is that Darkplaces supports .spr32 formats as well. Including alpha channel. The example in the gif above is of course only .spr format as it is the original s_explod.spr of Quake.

                  You say that you want to use Blood content. Well, you can use any blood sprite right away in darkplaces. Just be sure to edit its scale and coordinate position in an sprite editor of your choice and rename it to v_shot.mdl or v_shot2.mdl, ...
                  You do not even need a mod for this.

                  If you want to make a qc mod, you can make much more amazing things with it (especially when using engine extensions).

                  Have fun,
                  Seven

                  Comment


                  • #10
                    the main problem with monsters based in sprites are their angles
                    the invasion has begun! hide your children, grab the guns, and pack sandwiches.

                    syluxman2803

                    Comment


                    • #11
                      Ayyynn, any particular reason you're doing this for Quake instead of, say, GZDoom or EDuke32?

                      Originally posted by Seven View Post
                      The small mod compilation for example.
                      Har har har, anything to push your comm, eh? Kidding

                      Originally posted by Seven View Post
                      You say that you want to use Blood content.
                      As I understood it, he wants to make a game LIKE Blood, not to use Blood content. The guy's a graphic/audio designer, he probably doesn't need to rip content from other games.
                      ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
                      ♪ What a glorious feelin' I'm haaaaaaappy again ♪

                      Comment


                      • #12
                        Hello bfg666,

                        That is not how it works.
                        Everybody needs an understanding of how things are done first.
                        Then start to create new things.

                        And that is why ayyynn asks for examples. And that is why we help him.
                        Of course he will not create a game with copyrighted content, but he needs to learn how things are done a looong time before he releases / creats anything. So it is absolutely OK to playtest+learn with existing sprites/content from other games.
                        If you will make a mod once you will surely understand.
                        If you want to make a map, you will have to play lots of existing maps before you start making one and learn how to use mapping tools, right ? That the same here with mods.

                        If you have additional mods with open source code that are using sprites you can of course mention them. I mention my mod because I happen to know it and can directly guide him to the code blocks he needs to know. It has nothing to do with advertising anything. Just give him examples, so he can start looking at at once.

                        Best regards,
                        Seven

                        Comment


                        • #13
                          Thanks again for your quick replies! I just did some insideqc tutorials for replacing explosions with sprites from quake II and it works like a charm! I also did the tutorials for adding blood splats and used sprites, too.

                          I still need to understand better all these different sprite formats/animation, how to set pos/size correctly and what kind of file I can get inside that FIMG software. (my blood splats don't really sticks to the walls hehe)

                          I agree with Seven about ripping content, I'll work with open source stuff before i create my own to understand everything.

                          Originally posted by bfg666 View Post
                          Ayyynn, any particular reason you're doing this for Quake instead of, say, GZDoom or EDuke32?
                          Yeah, i'm already used to mapping for quake engine, and I cannot stand doom builder lightning system. I'm also really fan of the way your character moves in quake. And also thoses big square particules.. (i wonder if they can emit lights, thinking of MegaSphere!)

                          --
                          Last edited by ayyynn; 09-25-2016, 02:01 PM.

                          Comment


                          • #14
                            Originally posted by Seven View Post
                            I mention my mod because I happen to know it and can directly guide him to the code blocks he needs to know. It has nothing to do with advertising anything.
                            I know, Seven, it was just a joke. No criticism, only poking a little fun at you. Hence the "kidding" part.

                            he needs to learn how things are done a looong time before he releases / creats anything.
                            Yeah, I'm currently learning how to map, and even with a tool as user-friendly as Trenchbroom, it's far from being done at the snap of the fingers.
                            ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
                            ♪ What a glorious feelin' I'm haaaaaaappy again ♪

                            Comment


                            • #15
                              Originally posted by ayyynn View Post
                              Yeah, i'm already used to mapping for quake engine
                              You've made Quake maps? Released any?

                              And also thoses big square particules.. (i wonder if they can emit lights
                              I don't think so but I might be wrong about that. Seven would probably know.

                              This project looks pretty cool!
                              ♪ I'm skiiiiiiinnin' in the pain, just skiiiiiiinnin' in the pain ♪
                              ♪ What a glorious feelin' I'm haaaaaaappy again ♪

                              Comment

                              Working...
                              X