Gamestudio Links
Zorro Links
Newest Posts
Executing Trades on Next Bar Open
by vicknick. 06/13/24 08:51
Zorro Beta 2.61: PyTorch
by jcl. 06/10/24 14:42
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (Ayumi), 1,170 guests, and 2 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19059 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
STREAK/BEAM not working properly #311309
02/19/10 13:55
02/19/10 13:55
Joined: Sep 2009
Posts: 20
U
uniman Offline OP
Newbie
uniman  Offline OP
Newbie
U

Joined: Sep 2009
Posts: 20
whenever I try to attach the STREAK or BEAM flag to a particle
it shows up behind and to the right of the player instead of the assigned position. I am aware that these flags are not available with isometric cameras, however, I am using a simple FPS camera. this is the code,

vec_set(camera.x,player.x);
vec_set(camera.y,player.y);
vec_set(camera.z,player.z+38);
vec_set(camera.pan,player.pan);
vec_set(camera.tilt,player.tilt);

camera.pan -= 5 * mouse_force.x * time_step;
camera.tilt += 3 * mouse_force.y * time_step;
if(camera.tilt<-20)
{
camera.tilt = -20;
}
if(camera.tilt>40)
{
camera.tilt = 40;
}
player.pan = camera.pan;
player.tilt = camera.tilt;

the version is 7.80

if anyone can give me a clue as to what is causing this it would be greatly appreciated.

Re: STREAK/BEAM not working properly [Re: uniman] #311314
02/19/10 14:21
02/19/10 14:21
Joined: Sep 2009
Posts: 496
P
Progger Offline
Senior Member
Progger  Offline
Senior Member
P

Joined: Sep 2009
Posts: 496
streak and beam is only aviable in COmmercial and pro edition
WFG progger


asking is the best Way to get help laugh laugh laugh
Re: STREAK/BEAM not working properly [Re: Progger] #311318
02/19/10 14:47
02/19/10 14:47
Joined: Sep 2009
Posts: 20
U
uniman Offline OP
Newbie
uniman  Offline OP
Newbie
U

Joined: Sep 2009
Posts: 20
I neglected to mention that I am using the pro edition.
anymore solution?

Re: STREAK/BEAM not working properly [Re: uniman] #311603
02/20/10 22:25
02/20/10 22:25
Joined: Jul 2008
Posts: 1,178
England
M
MrGuest Offline
Serious User
MrGuest  Offline
Serious User
M

Joined: Jul 2008
Posts: 1,178
England
Originally Posted By: uniman
whenever I try to attach the STREAK or BEAM flag to a particle
it shows up behind and to the right of the player instead of the assigned position. I am aware that these flags are not available with isometric cameras, however, I am using a simple FPS camera. this is the code,

vec_set(camera.x,player.x);
vec_set(camera.y,player.y);
vec_set(camera.z,player.z+38);
vec_set(camera.pan,player.pan);
vec_set(camera.tilt,player.tilt);

camera.pan -= 5 * mouse_force.x * time_step;
camera.tilt += 3 * mouse_force.y * time_step;
if(camera.tilt<-20)
{
camera.tilt = -20;
}
if(camera.tilt>40)
{
camera.tilt = 40;
}
player.pan = camera.pan;
player.tilt = camera.tilt;

the version is 7.80

if anyone can give me a clue as to what is causing this it would be greatly appreciated.


vec_set sets Vectors, so:
Code:
vec_set(camera.x, player.x);

is the same as
Code:
camera.x = player.x; camera.y = player.y; camera.z = player.z;

so you only need
Code:
vec_set(camera.x, player.x);
vec_set(camera.pan, player.pan);
camera.z += 38;



the code you've posted so far isn't showing anything at all for particles which you need for the STREAK and BEAM to work

Re: STREAK/BEAM not working properly [Re: uniman] #311612
02/20/10 23:48
02/20/10 23:48
Joined: Oct 2004
Posts: 900
Lgh
rojart Offline
User
rojart  Offline
User

Joined: Oct 2004
Posts: 900
Lgh
Originally Posted By: uniman

if(camera.tilt<-20)
{
camera.tilt = -20;
}
if(camera.tilt>40)
{
camera.tilt = 40;
}

try this also instead from above
camera.tilt = clamp (camera.tilt, -20, 40);
Besides, I miss your particle code.


Regards, Robert

Quote
Everything should be made as simple as possible, but not one bit simpler.
by Albert Einstein

PhysX Preview of Cloth, Fluid and Soft Body

A8.47.1P
Re: STREAK/BEAM not working properly [Re: rojart] #311628
02/21/10 02:47
02/21/10 02:47
Joined: Sep 2009
Posts: 20
U
uniman Offline OP
Newbie
uniman  Offline OP
Newbie
U

Joined: Sep 2009
Posts: 20
thanks for the camera tilt snippet. that can be very usefull
for other things as well. as far as the particle code, it does this with ANY type of particle or code. even the ones that came with the engine. I have this problem for some time, with
two mini projects I have been working on. the only thing
the same between the two really is the camera script and some of the player script.


Moderated by  HeelX, Lukas, rayp, Rei_Ayanami, Superku, Tobias, TWO, VeT 

Gamestudio download | chip programmers | 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