Gamestudio Links
Zorro Links
Newest Posts
Zorro 2.70
by jcl. 09/29/25 09:24
optimize global parameters SOLVED
by dBc. 09/27/25 17:07
ZorroGPT
by TipmyPip. 09/27/25 10:05
assetHistory one candle shift
by jcl. 09/21/25 11:36
Plugins update
by Grant. 09/17/25 16:28
AUM Magazine
Latest Screens
Rocker`s Revenge
Stug 3 Stormartillery
Iljuschin 2
Galactic Strike X
Who's Online Now
5 registered members (Dico, AndrewAMD, TipmyPip, NewbieZorro, Grant), 15,791 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
krishna, DrissB, James168, Ed_Love, xtns
19168 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
trying to float an orb... #440294
04/23/14 01:43
04/23/14 01:43
Joined: Aug 2005
Posts: 199
houston
S
seneca Offline OP
Member
seneca  Offline OP
Member
S

Joined: Aug 2005
Posts: 199
houston
Hi all, sorry to bother, but I'm trying to have a patrol bot float or hover in one place up and down slowly. I know I wrote a code for it about 5 years ago, modified it from a aum lesson, I think. but I can't find the aum or figure out how I did it. searched for it here on the forum too, but still no answers.

Can someone help me? thanks a bunch!


a8 commercial
Re: trying to float an orb... [Re: seneca] #440296
04/23/14 06:20
04/23/14 06:20
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Code:
#define target_height skill80
...
my.target_height = XYZ; // either some value or for example c_trace and then target.z (when trace_hit != 0) + let's say 128
my.skill81 += 8*time_step; // may be a little too fast
my.skill81 %= 360;
my.skill82 = my.target_height+32*sinv(my.skill81)*time_step; // cover a vertical distance of 2*32 = 64 quants
c_move(me,nullvector,vector(0,0,my.skill82-my.z),IGNORE_PASSABLE);



"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: trying to float an orb... [Re: Superku] #440336
04/23/14 22:20
04/23/14 22:20
Joined: Aug 2005
Posts: 199
houston
S
seneca Offline OP
Member
seneca  Offline OP
Member
S

Joined: Aug 2005
Posts: 199
houston
It's not what I remember, but it works great!

thank you very much!


a8 commercial

Gamestudio download | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1