OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: chrisb1220 on 03 Oct 2002, 00:16:52
-
How can I get a tank to shoot at the ground like on the res. Under Hill mission?
-
One easy way to do that is to make an empty M2 and throw this in it's init field:
this setpos [getpos this select 0, getpos this select 1,-3]
this will sink it 3 meters underground.. if you named it you can make the tank fire with a dofire command... but I'm pretty sure they will fire on it automatically...
also if you go to the objects section of your Mission editor and place a West or East object instead of empty... (like sandbags or something) the enemy AI will fire on it also
-
Tanks are much nicer than people. You can just get them to fire at whatever you like by using the fire array command. Unlike the troops, they wont shoot straight into the air at will aim at whatever you tell them to.
-
I want it to keep on shooting every where just like in that mission. The shots on that mission were random and that's how I want mine.
-
Is there a decrypter for Resistance? If there is, take the mission to bits and see how BIS did it.
-
I tried that by extracting the .pbo and then opening it with the editer, but then it said this file is read only and nuttin showed up.
-
The BIS missions are encrypted. That means that when you un-pbo them all you get out is gibberish. Look at it in a text editor and you'll see what I mean. The ME can make no sense of it and, as you say, nothing appears.
What you need to do after the un-pbo is decrypt the result. I don't know if anybody has figured out how to decrypt Resistance files, I believe it can be done for earlier versions.
-
get pbo decrypter 1.5 it works on resistance.
-
Are you talking about the artillery? That was probably done by scripting.Make a gamelogic called gamelogic, and make a trigger.On the activation field type:
bomb = camcreate "heat120" getpos gamelogic (or something like that, it's been ages since I last used ofp)
It should make an abrams HEAT shell at gamelogic when the trigger is activated.
-
I want it to be random!
I was searching in the pbo and I found this script. Doesn't look like one though. It's called BigBaraBoom.sqs or somethin like that. This is it:
; Bombarding
; Run from mission:
; [who, A, B, C, "Name"] exec "BigBaraBoom.sqs"
; who - who runs the script (can be anybody)
; A - how many bombs
; B - diameter of "Area bombed"
; C - timout between two bombs
; D - name of the marker, which is in the middle of the "Area bombed"
_pos = getmarkerpos (_this select 4);
_bomb = "Bomb" createVehicle _pos;
_i = 0;
_j = _this select 1;
_k = _this select 2;
_t = _this select 3;
#LOOP
_u = random _k;
_bomb setpos [(_pos select 0) - _k/2 + random _k, (_pos select 1) - _k/2 + random _k]
_bomb setdammage 1;
~(random _t)
_bomb setdammage 0;
~(random _t)
_i = _i+1;
? prijeli : exit
? _i < _j : goto "LOOP"
deleteVehicle _bomb;
-
Can someone help me? :'(
I feel like this could be a good mission. I'm going to add voices to it too. ;)
-
Well.. in fact.. that mission did use an artillery script.... and you can find tons of arty scripts right here :
http://www.ofpec.com/editors/snippet_cat.php?id=2
most of the ones listed use a random function to make cam created shells fall randomly inside of a trigger's radius...
therefore increasing the trigger radius, and/or decreasing the number of shells will make the shells spread out farther on the battlefield, perhaps making it appear more random to the observer.
If one was so inclined... you could create a set of gamelogic points representing the impact points of your shells (i.e. g1-g8) and use this syntax in a trigger, or series of triggers with identical condition fields but offset by a few seconds utilizing the countdown funtion of said trigger.
b1="HEAT125" camcreate getpos g1
b2="HEAT125" camcreate getpos g2
this syntax could of course then be repeated ad infinitum
Plus the point is... who cares if you as a misson designer knows if they're falling randomly or not ::) creating the right timing and sequence of gamelogic targets, can yield a far superior effect anyways.