Create an account


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[SOLVED] Problem with setting new origin for func_clientwall

#1
Hello. Another noobish question about entities and QuakeC.
I'm trying to modify func_clientwall for my needs. I need it to be moved to another location when activated by trigger. At first I've tried to change origin of this entity somewhere in its code, without using triggers. For example, in client/wall.qc:
Code:
if(f & 2)
{
    self.origin_x = ReadCoord();
    self.origin_y = ReadCoord();
    self.origin_z = ReadCoord();
    setorigin(self, self.origin);
    // Added this
    vector neworigin = self.origin;
    neworigin_x = self.origin_x + 100;
    setorigin(self, neworigin);
}
OK, wall was moved when the game was started, but you still can't go through place where it was placed. What can be wrong here?
Reply

#2
So, you want a non-solid wall to move when triggered? what you might want instead is a func_door with a shader setting the nonsolid surfaceparm.

For example, if you have the texture textures/map_mapname/wall.tga, then the shader would look something like this:

Code:
textures/map_mapname/wall
{
         qer_editorimage textures/map_mapname/wall
         surfaceparm nonsolid

         {
                  map textures/map_mapname/wall
         }

         {
                map $lightmap
                rgbGen identity
                tcGen lightmap
                blendfunc filter
         }
}
[Image: 230.png]
Reply

#3
(04-13-2015, 09:07 AM)Mario Wrote: So, you want a non-solid wall to move when triggered? what you might want instead is a func_door with a shader setting the nonsolid surfaceparm.

No, it's different. I want solid entity to be removed when activated by trigger and to appear again when activated by another trigger. What I've planned to do is to instantly move it far away (actually, just outside the skybox), but making it invisible and non-soid when activated is nice too. Maybe I should try this way.

To explain better, there is video: http://www.youtube.com/watch?v=YB5dMcWmCmk
At 0:07 player jumps and "floor" disappears. When player will come here again this floor will be here again. This can be done using, for example, this thing I'm trying to do.
Reply

#4
A door may still do the trick here, just without the non-solid shader.

You're able to toggle their status rather than return after a delay, and also to set their distance/speed.
I won't go into the details here though, as NetRadiant does a good job of that already.
[Image: 230.png]
Reply

#5
Oh, thanks, didn't think about delay. Yes, door with delay and big movement speed can do the trick.
Reply

#6
damn you guys so smart
[Image: 38443.png]
Reply



Possibly Related Threads...
Thread Author Replies Views Last Post
  [SOLVED] setting proper git pushurl BuddyFriendGuy 0 1,400 04-07-2015, 09:44 PM
Last Post: BuddyFriendGuy
  Compiling problem liberty 2 3,054 11-07-2010, 07:08 PM
Last Post: liberty

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum software by © MyBB original theme © iAndrew 2016, remixed by -z-