Announcement

Collapse
No announcement yet.

Suggestion: add shadows to the player

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

  • Suggestion: add shadows to the player

    Looking at the screenshots from the unreal-engine-based game rune (www.runegame.com), I've got a great idea.

    Let's ad shadows to the player and his victims.
    So the player can see his reflection of his own shadow.

    Like this:


    It will gives the player a realistic feeling.
    It will give the thief the feeling that's he's on his own.
    The guards can see the reflection of the thief knocking him down
    it's not (hopefully) difficult to program. [Just import the shadowing code from rune]

    It will dramaticly down the fps.

    hopefully the thievery-team will ad the feature!
    Working on TH-Haven, the first singleplayer (and coِp) missionpack for thievery.
    Get more info about it on http://freyk0.tripod.com

  • #2
    IIRC UT doesn't support player detailed actor shadows... only a dark spot underneath the actor.

    Comment


    • #3
      What not can be supported,...can be programmed!

      They Just have to export the shadowcode from rune, take a look at it and reprogram it!

      It is simple as that!
      Working on TH-Haven, the first singleplayer (and coِp) missionpack for thievery.
      Get more info about it on http://freyk0.tripod.com

      Comment


      • #4
        Or for a better performance, you could always make an advanced blob shadow that points the way the light goes. And in fact it's so easy to program, I could make a prototype mutator in about half an hour or so (unless there's complications...).
        ]V[]V[

        Comment


        • #5
          ok, i've started timing.

          Comment


          • #6
            Don't forget to make the shadows invisible when the attached thief is invisible...
            Immortius' Forge

            Comment


            • #7
              The shadow code in Rune is in-engine c++ stuff, the source of which isn't released. Nor is the source c++ for UT released, so you couldn't put it into there even if you had it.

              So.... impossible!

              Comment


              • #8
                But.. lets just say i *could* get the source...

                Comment


                • #9
                  that would be useful, maybe we could find out more about the devlopers console then
                  This is my cool sig.

                  Comment


                  • #10
                    Hmm, a basic shadow code would be something like:

                    A shadow circle-blob which is attached to each player. Every tick the nearest light to the player is found, and the shadow is moved to lie on the ground in a position based on the position of the nearest light. That position would be (for a simple shadow) the line starting from the center of the light, passing through the center of the player and hit the ground beyond, streched to touch the players feet. The shadow would inherit the players visibility.

                    So basically each player has a circular shadow. If the nearest light is above the player, the shadow forms a circle below them. If the light is off to one side, the shadow would be an oval streching out from their feet.

                    Or at least that's my thinking.
                    Immortius' Forge

                    Comment


                    • #11
                      For a performance hit, you could take that concept a step further, and draw multiple shadows for each player cast by multiple light sources. Adjust the darkness of each shadow based on the nearness/brightness of each lightsource, with darker shadows being cast by closer, brighter lights, and lighter ones by dimmer, further lights.

                      Probably need a really phat rig to run that, though.

                      Comment


                      • #12
                        Originally posted by immortius
                        Hmm, a basic shadow code would be something like:

                        A shadow circle-blob which is attached to each player. Every tick the nearest light to the player is found, and the shadow is moved to lie on the ground in a position based on the position of the nearest light. That position would be (for a simple shadow) the line starting from the center of the light, passing through the center of the player and hit the ground beyond, streched to touch the players feet. The shadow would inherit the players visibility.

                        So basically each player has a circular shadow. If the nearest light is above the player, the shadow forms a circle below them. If the light is off to one side, the shadow would be an oval streching out from their feet.

                        Or at least that's my thinking.
                        Morrowind had a similar way of doing shadows. If there is more than one lightsource near you, though, the shadow tends to jump around quite a bit. I ended up turning off the shadows because they were annoying. The way around that would be LR's suggestion, but that will be hard on low-end computers...
                        It's not my fault everything you like is terrible.

                        Comment


                        • #13
                          Oh! Dual detail level shadow system. If there are lights within a specified area (say, 300 unit or so) use all of them to calculate a shadow fairly accurately, taking into account things like the lights shining in opposite directions, etc. Otherwise fall back on the basic shadow code. Basic light control should work fine for shadows from lights that are far away. Of course, you can ignore all lights whose radius doesn't reach the player.

                          I'm beginning to get the urge to try this myself, but I'ld probably work on scouting orbs that stick to guards first.
                          Immortius' Forge

                          Comment


                          • #14
                            Originally posted by LaughingRat
                            Probably need a really phat rig to run that, though.
                            That sounded funny.
                            The only constant is change.
                            (And I wouldn't have it any other way.)

                            Comment


                            • #15
                              Well, i have at home the game rune, so i can export the code!

                              actualy i own unreal, unreal napali, unreal tournament, deusex, undying and rune
                              (allmost all first and second generation unreal-engine based games)
                              Working on TH-Haven, the first singleplayer (and coِp) missionpack for thievery.
                              Get more info about it on http://freyk0.tripod.com

                              Comment

                              Working...
                              X