IPB

Welcome Guest ( Log In | Register )

Third Person Shoulder Camera with crosshair *(almost need some help), Dynamically Moving Objects
arcita
post Apr 8 2010, 08:29 PM
Post #1


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



Hey guys. With the help of dtneter, i dived into battlefield modding and within 3 days i almost finished my third person shoulder cam code.

With SatNav's laser and some tweaking of soldiercamera I got the third person effect with accurate aiming.
But I want to add a crosshair and so I added one by an emitter effect.
The only problem is that the crosshair is off due to the fixed position of the crosshair in the 3d space. (see diagram attached)

I just need to know how to dynamically change the x position of the crosshair in game.
Any advice?

-Thanks
Attached File(s)
Attached File  screenCross.jpg ( 65.61K ) Number of downloads: 71
Attached File  screen2.jpg ( 50.32K ) Number of downloads: 66
Attached File  crossHair2.jpg ( 24K ) Number of downloads: 72
Attached File  diagram.jpg ( 46.25K ) Number of downloads: 44
 
Go to the top of the page
 
+Quote Post
2 Pages V   1 2 >  
Start new topic
Replies (1 - 14)
MasterChiefRulZ
post Apr 8 2010, 09:05 PM
Post #2


NOM NOM NOM
Group Icon

Group: Mr. Admin
Posts: 9,029
Joined: 31-December 03
From: Home
Member No.: 48



Greetings arcita and welcome to BattleField Singleplayer! smile.gif

Gotta hand it to you, that 3rd person you have going there is rockin'. NICE. cool.gif


--------------------
QUOTE
If you're camping in a pasture field, don't get poop on your pillow. -----MasterChiefRulZ

My skins, sounds, and camos downloads
Go to the top of the page
 
+Quote Post
ba12348
post Apr 8 2010, 11:07 PM
Post #3


Major
****

Group: Soldiers
Posts: 226
Joined: 22-June 09
Member No.: 6,849



hmm... I can suggest something not completely unlike a crosshair, take a look at one of the guns from the chinese bf2 community which has a laser aimer-thingymajig
http://www.battlefieldsingleplayer.com/for...showtopic=14060
and can you pm me a link to that laser by a certain unmentionable person? ive been trying to find it for weeks

This post has been edited by ba12348: Apr 8 2010, 11:09 PM


--------------------
Do not do it! Do not even think about doing it! Do not even think about NOT doing it!

Oh noes! he did it!
Go to the top of the page
 
+Quote Post
arcita
post Apr 9 2010, 01:32 PM
Post #4


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



I need to know the following things.

1. How to attach a mesh to the camera only for the player's soldier.

2. How to attach a projectile to the camera that is invisible and fires constantly and displays a emitter upon collision with another mesh. (a bit like an invisible-no-damage bullet that fires automatically and when it hits the wall or another person it displays the crosshair.) *see diagram attached below.


Please answer number 2 with a greater priority because if it is answered, I can get the accurate crosshair up and running.

-----
@engineer: the link to the laser: http://www.battlefieldsingleplayer.com/for...p;mode=threaded and I already have the laser up and running as a backup in case the crosshair does not work. (check image 2, there is a laser coming out of the gun)

@chief: thanks for encouragement, but help would be more appreciated. smile.gif

If you guys can post/pm your xfire, I would like it very much.

This post has been edited by arcita: Apr 9 2010, 01:42 PM
Attached File(s)
Attached File  diagram2.jpg ( 39.9K ) Number of downloads: 18
 
Go to the top of the page
 
+Quote Post
clivewil
post Apr 9 2010, 07:46 PM
Post #5


meh.
Group Icon

Group: Mr. Admin
Posts: 2,007,959
Joined: 24-July 07
From: Perth, Western Australia
Member No.: 3,545



QUOTE
How to attach a projectile to the camera that is invisible and fires constantly

that part of your plan might cause you problems, because if the (crosshair emitter?) takes the form of a GenericFireArm and you still want to be able to use your normal handheld weapons too, then you'd effectively be using two weapons at once.

if you were to make your crosshair thingo a particle emitter instead, then your handweapons are freed up but you *might* not get the collision end effect (or you might need a custom particle made up before it will work) - i'm not certain about this though, sorry. experiment.


--------------------
Go to the top of the page
 
+Quote Post
arcita
post Apr 9 2010, 09:14 PM
Post #6


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



Sorry, it now occurs to me that the projectile is hard coded to only be used by the gun. It just seemed convenient to use the projectile class's already built in functions for collision effect.

I'm not sure how to start off with creating a trail/emitter that would display itself once it collides with another mesh. I have a vague idea of how it can be done, but i need a complete list of attributes related to trail system.
Do you know any attributes related to collision for the trail system? (I tried looking for a good library of functions but i couldn't find any. Does BF2 editor have a good list?)

If only satnav was here.......

This post has been edited by arcita: Apr 9 2010, 09:16 PM
Go to the top of the page
 
+Quote Post
arcita
post Apr 9 2010, 09:57 PM
Post #7


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



Let's just make this simple.

I need the camera to turn constantly to mouse movements.
In the third person camera, the body has to rotate 45 degrees in order for the camera to update its rotation.
I just need the camera to update its rotation constantly.

This post has been edited by arcita: Apr 9 2010, 11:57 PM
Go to the top of the page
 
+Quote Post
M.Combat
post Apr 10 2010, 02:55 AM
Post #8


Mediocre animator and modder
*****

Group: Soldiers
Posts: 1,969
Joined: 4-October 06
Member No.: 2,251



afaik camera updating speed is hardcoded, i remember someone earlier was messing around with 3rd person and due to the slow camera updating speed it couldnt be done.


--------------------
Go to the top of the page
 
+Quote Post
Xenephone
post Apr 10 2010, 05:17 AM
Post #9


AKA DJ Barney
Group Icon

Group: BFSP Team
Posts: 1,338
Joined: 2-December 07
From: UK
Member No.: 4,215



Wow ! Nice over the shoulder view there. I was always dead against third person until I played Mercs 2. Looks like this could add an interesting angle on things .


--------------------
Go to the top of the page
 
+Quote Post
arcita
post Apr 10 2010, 07:02 PM
Post #10


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



I can change the update speed, its pretty fast enough for a fps.
The problem is that the camera refocuses itself only after the soldier's body rotates 45 degrees.

I want to know if its possible to make the degree to change smaller, or make the soldier continuously walk a very small degree, or change where the bullets come out.

Any one of the following finish the mod.

This post has been edited by arcita: Apr 10 2010, 07:03 PM
Go to the top of the page
 
+Quote Post
imtheheadhunter
post Apr 10 2010, 08:11 PM
Post #11


Debug assertion failed! Text:people == stupid!
Group Icon

Group: Mr. Admin
Posts: 1,005,064
Joined: 8-March 06
From: The freaking Twilight zone!
Member No.: 1,609



I wonder, if you'll end up having to go about this completely different, and change the 1p LOD of the soldier to the 3p one, and move the 1p camera to where your 3p view should be? Basically just use the normal 1p camera instead of the 3p camera. BUT change the camera position, and change the 1p LODs and such to the 3p ones? Might be worth experimenting with to see if it'll actually work.

I dunno....just a stupid idea I guess.


--------------------
Go to the top of the page
 
+Quote Post
arcita
post Apr 10 2010, 09:05 PM
Post #12


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



@ithntr: yea, that was what i was trying to do. That's why i was curious on how to fire the bullet from an object other than the original 1p camera. I'll keep looking into it.
Go to the top of the page
 
+Quote Post
arcita
post Apr 10 2010, 11:26 PM
Post #13


Captain
***

Group: Soldiers
Posts: 46
Joined: 8-April 10
Member No.: 7,376



Modder Manifesto

Dear fellow modders of BF community, thank you very dearly for the support you have given me.

Four days ago, on a spirit to try something new, I decided to pick up Battlefield 2142 and start modding.

It was very confusing and hard to understand, and at first I wasn’t sure if I was able to accomplish my ideas.
But, with my constant questioning of other modders well past midnight, I was able to finish this small project.

The journey to completion, which is ever so near, has been torturous and painful.
This only added to my admiration to the modders who helped me and labored in the past to provide content for the public.

Although I am elated for the success of my mod, I am forced to admit a tragic fact.
The game, by natural course of time, is slowly dying. (One member, JONES, has left the bfcommunity this week)
Nevertheless, the nature of the modders I have seen throughout this project, I hope never changes.
For to mod is to proclaim that even though corporations may have greater firepower, the vitality and audacity of individual creativity/public collaboration occasionally triumph.
Although, with time, the game may die, this spirit will never die within us.

I am proud to be among people like you.
I am proud to be a modder.


I would like use this opportunity to thank Dtneter for unparalleled guidance throughout this time and Imtheheadhunter for the last crucial piece of information needed to complete this mod.

Video: Third Person Shoulder Cam Mod

This post has been edited by arcita: Apr 10 2010, 11:27 PM
Go to the top of the page
 
+Quote Post
GroovyDawg
post Apr 11 2010, 02:48 AM
Post #14


Groovy, you are GJ.
Group Icon

Group: BFSP Team
Posts: 3,741
Joined: 30-July 08
From: On vacation.
Member No.: 5,410



Simply spectacular. clapclap.gif

Super pats on the back to you Arcita.


--------------------
~I salute you, the AIX gentlemen.~

U MAD? ¯\_(ツ)_/¯

Asus G73JH-X3| Intel® Core™ i7-720QM | 8GB DDR3 1333 RAM | ATI Mobility Radeon 5870 1GB GDDR5 | 2x320GB Seagate 7200 RPM | 17.3" LED 1920x1080
Go to the top of the page
 
+Quote Post
Xenephone
post Apr 11 2010, 05:12 AM
Post #15


AKA DJ Barney
Group Icon

Group: BFSP Team
Posts: 1,338
Joined: 2-December 07
From: UK
Member No.: 4,215



Nice vid. 2142 suddenly looks like some spiffy new arcade cabinet. I rather like the red laser but I guess it might not work for a lot of people because it appears to come from somewhere in the middle of the screen.


--------------------
Go to the top of the page
 
+Quote Post

2 Pages V   1 2 >
Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 21st September 2014 - 10:05 AM