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
3 registered members (TipmyPip, AndrewAMD, NewbieZorro), 16,055 guests, and 7 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
Attaching camera to an entity. #246413
01/15/09 03:31
01/15/09 03:31
Joined: Aug 2006
Posts: 70
NJ
S
SirCamaris Offline OP
Junior Member
SirCamaris  Offline OP
Junior Member
S

Joined: Aug 2006
Posts: 70
NJ
Hello,

I'm trying to attach a first-person camera to a sprite entity and make it move along with it. I vec_set the camera coordinates with the eye-level of the sprite; this works fine. I attached an action to this sprite which moves it as I planned, with the exception that the camera doesn't move along with it. When I created a view, I'm unable to set the genius property to the sprite entity. I tried this with and without defining the sprite entity. The script, genius = "player.bmp"; doesn't change color like the rest of the properties in the View entity. I'm not sure why this isn't working. Please post your comments. Thank you.

Re: Attaching camera to an entity. [Re: SirCamaris] #246414
01/15/09 04:56
01/15/09 04:56
Joined: Jul 2008
Posts: 553
Singapore
delinkx Offline
User
delinkx  Offline
User

Joined: Jul 2008
Posts: 553
Singapore
search this forum.. this has been posted earlier..


A7 commercial Team / VC++ 2008 Pro
homepage | twitter | facebook
Re: Attaching camera to an entity. [Re: delinkx] #246442
01/15/09 09:01
01/15/09 09:01
Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Cowabanga Offline
Expert
Cowabanga  Offline
Expert

Joined: Aug 2008
Posts: 2,838
take me down to the paradise c...
Put this in the Entity's action:
Code:
while(1)
{
     camera.x = player.x;
     camera.y = player.y;
     camera.z = player.z;
     camera.pan = player.pan;
     camera.tilt = player.tilt;
     camera.roll = player.roll;
     wait(1);
}


Re: Attaching camera to an entity. [Re: Cowabanga] #246631
01/15/09 22:36
01/15/09 22:36
Joined: Aug 2006
Posts: 70
NJ
S
SirCamaris Offline OP
Junior Member
SirCamaris  Offline OP
Junior Member
S

Joined: Aug 2006
Posts: 70
NJ
This works... Thank you.


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