Gamestudio Links
Zorro Links
Newest Posts
Newbie Questions
by fairtrader. 12/06/23 11:29
Zorro Trader GPT
by TipmyPip. 12/04/23 11:34
Square root rule
by Smallz. 12/02/23 09:15
RTest not found error
by TipmyPip. 12/01/23 21:43
neural function for Python to [Train]
by TipmyPip. 12/01/23 14:47
Xor Memory Problem.
by TipmyPip. 11/28/23 14:23
Training with command line parameters
by TipmyPip. 11/26/23 08:42
Combine USD & BTC Pairs In Asset Loop
by TipmyPip. 11/26/23 08:30
AUM Magazine
Latest Screens
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Tactics of World War I
Who's Online Now
7 registered members (fairtrader, Quad, miwok, Martin_HH, AndrewAMD, alibaba, dpn), 581 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
fairtrader, hus, Vurtis, Harry5, KelvinC
19019 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Bullets to target #303260
12/27/09 15:11
12/27/09 15:11
Joined: Dec 2009
Posts: 74
Romania,Bucharest
Ted22 Offline OP
Junior Member
Ted22  Offline OP
Junior Member

Joined: Dec 2009
Posts: 74
Romania,Bucharest
Hi!Does anyone know how can i make a gun that shoot bullets exacly where i point with my crosshair?
So, i got a model,a crosshair that is standing in the middle of the screen and ofcourse bullets shooting.But i want to know how can i make the bullets go where my crosshair is.

Last edited by Ted22; 12/27/09 15:19.
Re: Bullets to target [Re: Ted22] #303266
12/27/09 15:46
12/27/09 15:46
Joined: Mar 2007
Posts: 112
MikeS Offline
Member
MikeS  Offline
Member

Joined: Mar 2007
Posts: 112
Use vec_for_Screen or Vec_to_screen.

Search in the manual for this, ull find something helpfull.

Greetings

Mike

Re: Bullets to target [Re: MikeS] #303277
12/27/09 17:05
12/27/09 17:05
Joined: Dec 2009
Posts: 74
Romania,Bucharest
Ted22 Offline OP
Junior Member
Ted22  Offline OP
Junior Member

Joined: Dec 2009
Posts: 74
Romania,Bucharest
Can u show me a little example please?

Re: Bullets to target [Re: Ted22] #303283
12/27/09 17:31
12/27/09 17:31
Joined: Nov 2007
Posts: 1,143
United Kingdom
DJBMASTER Offline
Serious User
DJBMASTER  Offline
Serious User

Joined: Nov 2007
Posts: 1,143
United Kingdom
Make the crosshair snap to the mouse, in a while loop and then you can use mouse_dir3d/mouse_pos3d to fire the bullet in the '3D' direction of the mouse.

The manual has some small samples of this.

Re: Bullets to target [Re: DJBMASTER] #303284
12/27/09 17:40
12/27/09 17:40
Joined: Dec 2009
Posts: 74
Romania,Bucharest
Ted22 Offline OP
Junior Member
Ted22  Offline OP
Junior Member

Joined: Dec 2009
Posts: 74
Romania,Bucharest
THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU,THANK YOU!!!!
You are a genius!Thanks!


Moderated by  HeelX, rvL_eXile 

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