Jump to content

RazorX

Member
  • Content Count

    123
  • Joined

  • Last visited

  • Medals

Posts posted by RazorX


  1. You're right in 1 aspect - that's the simplest way if you really don't care what track is playing. In other cases script it. And also look in the module's source, you'll find something interesting :P Also, the module plays the tracks randomly, modify the loop and make them play in any order you want. I just dislike giving me a simple tool which I can't modify when in only few lines of code I can make something exactly what I want


  2. Yep, but tell you the truth, ArmA2 engine is a bit irritating when it comes to media. You need to know the length of tracks. The script may look something like this

    script.sqf

    ArrayOfTracks = [.......];
    ArrayOfTrackLengths = [.......]; //must be in the same order as above
    
    while {true} do
    {
      _index = floor random (count ArrayOfTracks);
      playMusic (ArrayOfTracks select _index);
      sleep (ArrayOfTrackLengths select _index);
    };

    It's the simplest solution


  3. I doubt the mess version. Note that the effects of lethal doses of radiation are observed within up 6 weeks. Holy shit, it's a huge amount of time in agony. To kill a human within a period of minutes requires tremendous amount of gamma particles, such radiation never existed even in regions of Chernobyl. Most of you don't know about the accident in Chelyabinsk, read about it and you will know that Chernobyl was only a little disaster in comparison to that.

    Bleedings what you mentioned takes place after at least 2 days after being irradiated, mainly from digestive system, rarely from skin - the skin must have been damaged earlier or take at least 1000R and still the deformations are observed at least after a week. The skin turns red after a couple of hours after being irradiated but this effect lasts only up to 24 hrs, after a week the skin stars to turn dark red and deformations start.

    Gastric mucosa is being completely destroyed and the organism can't take any nourishment, there is a huge body mass loss. Radiation destroys the immune system, even light wounds are sources of infection. After a long period of time people often die of leukemia. After a month first signs of cancer can be observed.

    In all this I mean that killing a human by radiation in a period of minutes is simply impossible. Computer games like Stalker or any other of this kind showing radiation killing in seconds are simply imaginary and have nothing to do with reality. During first months after the Chernobyl explosion only 31 people died of radiation sickness, most of them were the scientists which were inside the power plant and they didn't died instantly though.

    Just stop watching too many sci-fi movies and take some books instead.

    If you want to implement a realistic radiation, you have to use realistic lengths of time, sorry.


  4. _unit = _this select 0; //must be a unit, not a vehicle
    _target = _this select 1; //must be a vehicle
    
    scopeName "notFollow";
    for "_a" from 0 to 1 step 0 do
    {
    _unit domove (_target modelToWorld [0,-5,0]);
    waituntil {unitReady _unit};
       //prevent crashing into the car that is being followed when not moving
    if ((position _unit distance position _target) < 12) then
    {
    	vehicle _unit setvelocity [0,0,0];
    }
    else
    {
           //stop following while the unit is too far away
    	if ((position _unit distance position _target) > 1000) then
    	{
    		breakTo "notFollow";
    	};
    };
    };

    I've written this code. It makes a unit follow another unit (written for vehicles). It's a pretty good script, works well if both units are AI units. Has some bugs but I really think it's the best of the simple solutions. Feel free to modify it, the loop is infinite and you need to script more events when you want the chase to end. For now the only condition to exit the loop is when the followed vehicle is 1km away from the follower.


  5. Well, doMove seems like the most logical way, though you could give moveTo a shot; apparently it's a lower level move command so it may override some AI FSM behavior.

    I think domove is best. Works great on units, but when used on vehicles, the driver slows down after doMove is issued to calculate new route to the target. With 3- or 2-second sleep it means, the driver slows down pretty often, so that's the first bug when used on drivers of vehicles. The first vehicles drives normally but the one that follows it drives a bit too slow to catch up to it. And I can't extend the sleep time because the results will be worse.

    EDIT

    _unit = _this select 0; //must be a unit, not a vehicle
    _target = _this select 1; //must be a vehicle
    
    scopeName "notFollow";
    for "_a" from 0 to 1 step 0 do
    {
       _unit domove (_target modelToWorld [0,-5,0]);
       waituntil {unitReady _unit};
       //prevent crashing into the car that is being followed when not moving
       if ((position _unit distance position _target) < 12) then
       {
           vehicle _unit setvelocity [0,0,0];
       }
       else
       {
           //stop following while the unit is too far away
           if ((position _unit distance position _target) > 1000) then
           {
               breakTo "notFollow";
           };
       };
    };  

    New script written, works almost perfectly ;)


  6. Analysing your code here, I see, you are using waypoints to make one group follow another group. But I want a single unit from one group to follow a single unit from another group (groups with no formation, because units in my groups don't move in formation) or a unit from the same group following another one from the same group (and not using AssignTeam). That's a bit of problematic code to invent especially when scripted for following vehicles

×