[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4668: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4670: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4671: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4672: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3815)
Battlefield Modding Tutorials BFMODS • View topic - is it hardcoded?

Battlefield Modding Tutorials BFMODS

Battlefield Modding Tutorials
It is currently Thu May 23, 2024 2:14 am

All times are UTC




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 22 posts ]  Go to page 1, 2, 3  Next
Author Message
 Post subject: is it hardcoded?
PostPosted: Wed Jan 14, 2009 8:48 pm 
Offline
User avatar

Joined: Thu Oct 23, 2008 6:47 pm
Posts: 935
Location: Charleston S.C.
I can't find in the hand weapons where it says what button is fire and zoom. because I'd like to work on a melee system for vanilla. press "e" and (with the proper animations) you will throw a melee attack with gun which will use a knife projectile. At least that's the idea. I'm not sure it's possible serverside or not. so is the fire/zoom buttons hard coded into the game? thanks

_________________
Image


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 2:35 am 
Offline

Joined: Mon Aug 16, 2004 12:00 am
Posts: 2120
No. That can not be done. Only certain buttons can fire weapons, and E would have to be assigned to something by the client anyway. In effect you would be hard-coding something that is not found inside the con files of the game anyway. This game does not support good keybinds and only uses macros to describe what key does what, not necessarily what it is bound to.

You might be able to do it with right-click, see Bayonet in Road to Rome.


Top
 Profile  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 2:51 am 
Offline

Joined: Mon Oct 09, 2006 12:51 pm
Posts: 782
Well it is possible to modify the keys to fire the weapons, for instance I could change the zoom from the Alt Fire (right click) to another command, its just conflicting with whatever else is using that command.

There is a way to script new keys into the game, the files can be found in BF1942 settings folders, and you can re-arrange the scripts so different keys are used to different commands, for instance theres no need for the fire button to use both, Mouse click and the space bar for airplanes, so you could change that so that there is only the mouse click, then use that defined Control method apply it to something else.

You could also certaintly get the animations to play, animation triggers can be scripted with a few hours of work, so yes technically I could script the gun to bayonet thrust when I right click, but thats where the good things end and the problems begin. I've tried long and hard to try and get a gun to fire a secondary projectile, much like the Machine guns on the tanks, and It just doesnt seem to work, not matter how hard I try.


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 3:44 am 
Offline
User avatar

Joined: Thu Oct 23, 2008 6:47 pm
Posts: 935
Location: Charleston S.C.
Well I was hoping that I could do that. Hmm... I'm not sure what I can do. I tried adding the code ObjectTemplate.InputFire c_PIDrop into the colt objects.con. it broke the trigger completely. if you can't seem to get a gun to shoot two different projectiles then how can the one in ROR do it? It doesn't actually shoot a bullet out but same idea with the bayonetprojectile.

_________________
Image


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 4:45 am 
Offline

Joined: Mon Oct 09, 2006 12:51 pm
Posts: 782
you inspired me, and I figured it out! I've not got the bayonet animation working on the alt fire as opposed to a zoom, and a bayonet secondary fire for the No4, and it works!

I'm thinking itll be useful come time I start working on pirates again, now I just gotta see if the Walk animation can be edited to make sprint.


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 4:45 pm 
Offline
User avatar

Joined: Thu Oct 23, 2008 6:47 pm
Posts: 935
Location: Charleston S.C.

_________________
Image


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Thu Jan 15, 2009 7:36 pm 
Offline

Joined: Mon Oct 09, 2006 12:51 pm
Posts: 782
Actually yes, what we do is we make a second set of animations, that link to each other, those animations raise the iron sights of the weapon, using the C_PIWalk command, for shooting, the Alt Fire or right click serves as the bayonet thrust, and the left click as the rifle shot.

It would take a little work but with the proper coding I believe its more than possible


Top
 Profile Send private message E-mail  
 
 Post subject: Re: is it hardcoded?
PostPosted: Fri Jan 16, 2009 7:32 pm 
Offline

Joined: Thu Apr 19, 2007 7:38 pm
Posts: 177
Hi
I'm working on my old minimod trying to put more features in there...might be usefull for BfV2 btw 8-)
Ok so i started with shovel and then thought i could bring it to rifles
To make it short, i've set an alt weapon with plantation knife animation that when you press RMB, you switch to the killing shovel
That's BfV, so when you spawn with an engineer kit and select shovel, you get the killing one cause you don't have the tunnel (NVAshovel is set to cantSelectWhenNoAmmo 1) If you're carrying the tunnel you still can switch at will from an weapon animation to another.

cause i did this trick with M16 as a start on rifles
So that thing disabled the zoom and now i press RMB i switch to a different animation i called M16hit where the soldier hold his weapon reversed and uses it for melee (i'd like to make it more real but that's just tests i'm doing so i still use the plantation knife animation that fits perfect btw)

Now here's the problem i get to:
Shovel works perfect and i can switch when i want, but the M16 i can't switch to M16hit when the mag is empty
Dunno if i'm clear...my first magasin isn't empty yet, i can switch weapons>when it's empty i can't switch (that's where it would be interesting to have it)...then i reload the M16 and can switch again :shock:

Even with changeWeaponWhenNoAmmo 1 that only works when soldier runs out of magasins...
The only solution i see for now is one mag only wich sux big time :roll:
***EDIT***Autoreload 1 is a solution (dunno why i always have is unchecked...)

Now what am i doing here? i'm interseted with that PIwalk story for the zoom ;-)

_________________
Image


Top
 Profile Send private message E-mail  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 22 posts ]  Go to page 1, 2, 3  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 45 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group