[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4787: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4789: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4790: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4791: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
InsideQC Forums • View topic - problems with movetogoal

problems with movetogoal

Discuss programming in the QuakeC language.

Moderator: InsideQC Admins

problems with movetogoal

Postby Nahuel » Tue Feb 05, 2013 7:32 pm

is there a way to get some function like movetogoal but working with z value?? movetogoal doesn´t work with the z axys (the monsters doesnt consider height), i really need a movetogoal with z value or something similar. Thanks :)
hi, I am nahuel, I love quake and qc.
User avatar
Nahuel
 
Posts: 495
Joined: Wed Jan 12, 2011 8:42 pm
Location: mar del plata

Re: problems with movetogoal

Postby ceriux » Tue Feb 05, 2013 9:35 pm

this tutorial gives the ogre z-awareness when aiming. maybe useful? http://inside3d.com/showtutorial.php?id=52
User avatar
ceriux
 
Posts: 2230
Joined: Sat Sep 06, 2008 3:30 pm
Location: Indiana, USA

Re: problems with movetogoal

Postby qbism » Wed Feb 06, 2013 4:49 am

Need a waypoint system?
http://shoresofnis.wordpress.com/guides ... e_dynamic/
"If you have mapped for HL2, then you already understand roughly how this works.
You place path_node entities all over the floor of the map and at runtime, these entities will connect with each other to form a graph.

Once this is done, monsters search for the player through this connected system of path_nodes and use them to make decisions on where to move next. This allows them to, for example, path up a spiral staircase or run away from you to get to stairs leading to you instead of remaining trapped in a pit."
User avatar
qbism
 
Posts: 1236
Joined: Thu Nov 04, 2004 5:51 am

Re: problems with movetogoal

Postby Seven » Wed Feb 06, 2013 9:33 am

Hello Nahuel,

I am not sure for what reason you need it. If the links + tips given from ceriux and qbism does not help, maybe necros explanation from a while ago can help you further ?
Please try this thread:
viewtopic.php?f=2&t=4217&p=38873&hilit=movetogoal&sid=89f2142ce59135a22a632c0527342c34#p38873

When you speak about "consider height". Do you mean, that the monster shall move upwards from the ground (fly ?). Then its movetype and flags must be changed as well.
I am just poking around in the fog here :)
Seven
 
Posts: 301
Joined: Sat Oct 06, 2007 8:49 pm
Location: Germany

Re: problems with movetogoal

Postby Nahuel » Wed Feb 06, 2013 10:14 am

Thank you guys , sorry for my lack of explanation. What I need is basically a mobile camera system. time ago I programmed a basic system of cameras in csqc.


Some cameras moves based on player's origin. What do I think is create a simple system of cutscenes, and to change the origin of the cameras i thought it was good idea to use movetogoal. Movetogoal is really buggy to do the work and the cameras fails and have "strange" behaviors. What do you think is easier to use for move a single entity from one point to another in qc? I thought use velocity_ values​​, but it's really complicated do this from scratch. how can i do rhis? any example? What I need is:
-move a simple entity from a point to another point in a map with precise origin and angles.
- When this entity finishes its predetermined path can activate triggers and other stuff. How do you think I can do that? I tried as func_train, but does not consider my angles, and is not "fluid" for what I need.Thank you for your help
hi, I am nahuel, I love quake and qc.
User avatar
Nahuel
 
Posts: 495
Joined: Wed Jan 12, 2011 8:42 pm
Location: mar del plata

Re: problems with movetogoal

Postby Spike » Wed Feb 06, 2013 11:31 am

movetogoal will not really do anything except horizontal stuff. its for MOVETYPE_STEP monsters stepping through the world, nothing more. it can do vertical stuff only for FL_FLY or FL_SWIM monsters, and very much as a if (target.origin_z > self.origin_z) self.origin_z += 16;
its really dumb, and doesn't have any routing. it'll let the monster run away from its goal more as a bounce than anything inteligent.

there's a lot of ways you can write a routing algorithm. most are basically a flood-fill routine. that is, you walk each node to every single other node counting how long it took, then walk through backwards taking the cheapest route.
routing-type algorithms are generally fairly simple in concept (as opposed to implementation and optimisation), so you should be able to find a good overview of the various possible algorithms.
most maps will need waypoints of some kind. You can use lots of ways to auto-generate waypoints. interrogate the bsp to find surfaces, flood-fill the world, use light entities, periodically placing waypoints underneath players, etc.
the real problem is determining connectivity of waypoints - velocity, gravity, size, etc. which of course depends upon the previous node, which makes following the route order dependant. with stepping monsters, there is no velocity or gravity, yay.
.
Spike
 
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK


Return to QuakeC Programming

Who is online

Users browsing this forum: No registered users and 1 guest