Page 3 of 4

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Mon Apr 23, 2018 10:01 pm
by russ
Out of curiosity, what actions did you test?

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Tue Apr 24, 2018 5:42 am
by Swaffy
I can't even find the code for the damn thing, hah ...

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Tue Apr 24, 2018 5:55 am
by russ
I don't mean the code, I mean what did you try? Shooting at it? Throwing grenades at it? Pushing it with a jeep? etc.

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Wed Apr 25, 2018 2:14 am
by freddy
I think it atleast needs ObjectTemplate.mass # if its to interact with other objects

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Wed Apr 25, 2018 2:45 am
by Diamondback
freddy wrote:I think it atleast needs ObjectTemplate.mass # if its to interact with other objects
Not necessarily: http://bfmods.com/viewtopic.php?f=6&t=18076

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Thu Apr 26, 2018 2:38 am
by Swaffy
Classical Modder wrote:
freddy wrote:I think it atleast needs ObjectTemplate.mass # if its to interact with other objects
Not necessarily: http://bfmods.com/viewtopic.php?f=6&t=18076
give the flag a mass just for the sake of testing, you never know...

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Thu Apr 26, 2018 3:36 am
by Diamondback
Swaffy wrote:
Classical Modder wrote:
freddy wrote:I think it atleast needs ObjectTemplate.mass # if its to interact with other objects
Not necessarily: http://bfmods.com/viewtopic.php?f=6&t=18076
give the flag a mass just for the sake of testing, you never know...
Fine lol, but I know it won't work

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Thu Apr 26, 2018 10:16 pm
by Swaffy
SPOILER
Image

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Sun Oct 14, 2018 6:22 pm
by Diamondback
So today I was looking at the Network.con file for the Flag object and I came across this:

(Taken from Objects/Items/Flag/Network.con):

Code: Select all

NetworkableInfo.createNewInfo FlagBodyInfo
NetworkableInfo.setHasOrientation 1
NetworkableInfo.setBasePriority c_NIGhostAlways
NetworkableInfo.setPredictionMode PMNone
The Flag object has different Network Info compared to a regular PCO. If we take the Jeep for example, this is what we get:

Code: Select all

NetworkableInfo.createNewInfo WillyEngineInfo
NetworkableInfo.setPredictionMode PMLinear
I am not sure, but I think the NetworkableInfo.setBasePriority c_NIGhostAlways line tells the Flag object to essentially be a ghost, i.e., it doesn't interact with the environment (except for the terrain). I will try to remove that line and change the PredictionMode to PMLinear and see if it changes anything. So far I think this is the best clue we have as to why the Flag object doesn't interact with anything.

Re: Fixing the CTF flag object so it doesn't fall through me

Posted: Sun Nov 04, 2018 12:15 am
by russ
Sorry man, it's hardcoded. The position of the flag gets set to the position of the "vehicle" that dropped it, and the height gets set to the height of the terrain at that point (plus 1.5). You might be able to combine it with some other object so it interacts after that, but there's nothing that can be done short of patching the executable that will change the drop position.