Jump to content

Tomsk

Member
  • Content Count

    12
  • Joined

  • Last visited

  • Medals

Community Reputation

0 Neutral

About Tomsk

  • Rank
    Private First Class
  1. Thanks Muzzleflash that worked great. Wow nowhere in the OFPEC COMREF for execVM does it mention that it runs in a separate thread! Worthy of a mention I think, so I'll have to add a comment to that effect. :D I didn't notice it in in the bistudio wiki either, but looking more closely I notice that it's vaguely mentioned in one of the comments. Not a well documented feature it seems. Many thanks! Tomsk
  2. Hello, I'm trying to create a reusable library of scripting functions which is proving to be surprisingly challenging. Now because I have lots of functions, I want to use the style: MyFirstFunc = { hint "Hello world!"; }; MySecondFunc = { hint "Hello world, again!"; }; Functions are defined as global variables. This style allows you to define multiple functions per file, which is important for what I'm doing. So I take these two function, and put them in a file "MyLibrary.sqf". Now I open up another sqf called from my mission, "dosomething.sqf"; And I call ... [] execVM "MyLibrary.sqf"; [ 1, 2, 3 ] call MyFirstFunc; And Arma 2 tells me that it can't find MyFirstFunc ... I add a trace line in MyLibrary.sqf to check that it is being executed, it definitely is being executed. So it seems that execing a script that defines functions as global variables does not cause those global variables to be accessible to the next script. So next, I try the rather dubious #include mechanism ... #include "MyLibrary.sqf"; [ 1, 2, 3 ] call MyFirstFunc; Hoorah! Success Arma calls my function and shows me a hint for 'Hello world'. Awesome, so now I'll just move my reusable MyLibrary.sqf out of the mission folder ... into the 'Documents\Arma 2\scripts' folder ... try again and Arma 2 blows up (CTD) saying it can't find the script. So I try this instead. #include <MyLibrary.sqf>; // Note the <> brackets instead of "" quotes. [ 1, 2, 3 ] call MyFirstFunc; Same result. Maybe I messed up, so I switch back to this: [] execVM "MyLibrary.sqf"; [ 1, 2, 3 ] call MyFirstFunc; But with my MyLibrary.sqf still in Documents\Arma 2\scripts. Apparently that works as well as it did before, it does execute MyLibrary.sqf but the functions within it still don't work. So it seems that execVM doesn't work with the 'multiple functions per sqf' style ... and #include only works if the script is in the same directory. Even if #include can be made to work from other directories ... can it still be made to work if I put my scripts in a PBO (which is my ultimate goal)? So my question is as follows: Does anyone have any idea how you go about creating a reusable library of scripts in the multiple-functions-per-script style?
  3. Hello, I have a large number of scripts that I'd like to share between several different missions. So I had the clever idea that rather than copying each script into each mission folder, and ending up with 10 versions of each script. Instead I should put them in a PBO and stick that in a mod folder and load my scripts as a mod. I've found the cpbo tool and have worked out how to create the .pbo file with the scripts in it, how to create a mod folder and have Arma2 load the mod and all the rest. What I haven't found out is how I can use my scripts from my mission files. I used to use: #include "Tomsk_Utils.sqf" to load the functions in one of my utility scripts. This worked fine when their was a copy of that script in the same folder as the mission. But having moved the script to a .pbo this doesn't work any more. Does anyone know how I can make use of the functions and macros in my script now the script is in a PBO? Cheers Tomsk
  4. Hello, Back in the OFP days I built a number of small team "special forces" coop missions for my friends. Recently I've been trying to do the same in Arma 2 1.09 (no OA or other expansions). The trouble I'm having is getting realistic (and fun) behaviour out of the enemy AI. The first problem I found, is that the AI can see through the grass, which was easy to fix: turn the grass off. However, even without grass issue the AI seem to have an incredible ability to spot. I've got the AI on 'Safe' mode and they will usually spot me before I can spot them, and I know where they are placed! This makes 'sneaking up' on the AI virtually impossible, which kind of ruins the point of SF style missions ... Secondly when you do engage the AI, they frequently just run away. Which again doesn't make for a very interesting mission ... I've tried: - playing about with the AI skill settings, including using setSkill [ "spotTime", x ] and setSkill [ "spotDistance", x ]. As far as I could tell these had limited effect. - using mods such as ACE2, ZeusAI, SLX AI etc. These seem to improve the AI in other ways (better formations etc.), but they are still eagle eyed. Have other people observed similar problems with the Arma2 AI, and does anyone know a good solution to get more realistic behaviour out of them? Cheers Tomsk
  5. Tomsk

    Selecting weapons in briefing?

    Thanks I'll try that :)
  6. Tomsk

    Selecting weapons in briefing?

    We generally have someone fill each role (team leader, automatic rifleman, demolitions, etc.) so it's more a case of customisation. Someone would prefer to take an extra smoke grenade, or would prefer the ACOG to the reflex sight. Trying to get one person to administer all this is a real pain, particularly since if I ask the team leader to change my gear I have to explain what I'd like, and I can't see the changes he's made, so he has to explain what he's done. It was just taking up way too much of our time. So ... I put everyone in their own group. When the mission starts a script automatically joins all the groups to the leader group. Problem solved :) Note: if anyone else tries to do this the only minor problem is that when you are in the briefing screen the mission init scripts have already run. This means that if you just put "join" in the init script it joins too early. I solved this by detecting whether the player had moved from their start position, and if they have then they are joined to the leader team. This works, but perhaps there is a better way to do this so that it only runs the script when the mission really has started ...
  7. Tomsk

    Selecting weapons in briefing?

    Right, these are actually all small team "special forces" missions. I'm also playing them with a select group of friends, so there's no question of people not being trusted. As a result people are allowed to take whatever gear they like, there is no shortage of anything so it's simply a question of what is most appropriate for the mission. If everyone wants to take an RPG that's fine, although for most mission we wouldn't because we'd think that was a bit silly :) Generally weapons crates are a bit of a pain for SF missions, the reason is that you want any gear to be available and there's no crate that contains all possible options. So you end up searching between multiple crates for the item you want .. Hence the preference for using description.ext
  8. Tomsk

    Selecting weapons in briefing?

    hmm that's a bit of a pain. Since that means each member either needs their own set of waypoints and synchronisers, or all the groups need to be joined together on start. I'll have a go and see if I can make it work. Cheers Tomsk
  9. Tomsk

    Selecting weapons in briefing?

    Hello, I had my first OFP multiplayer game a few days ago with a few friends (only ever played it singleplayer before that). Generally it all worked well, but there was one minor thing that bugged us. We found that only the squad leader could change weapons on the 'GEAR' tab in the briefing screen, everyone else was either stuck with the weapons that were assigned by default - or had to ask whoever was squad leader to change their weapons for them (very tedious). Is there an option somewhere to enable anyone to change their weapons in the briefing, not just the squad leader? Thanks Tomsk
  10. As I see it, the problem is that in real life we have all sorts of sensory inputs to help us deal with the momentum. We have balance mechanisms in our ears, we can feel the position of our limbs and the way they are moving. All of this means that IRL I can position myself very naturally, even with the momentum. However in a computer game all you've got is a mouse, a keyboard and a screen. That's not nearly the same level of input, and the result is that dealing with the momentum doesn't feel natural, it feels like something you have to fight against ... As for being able to turn 180 degrees in a heartbeat and fire with instant accuracy, this has been solved in many other games. The very simplest solution is the kind of thing employed in Rainbow Six Raven Shield, or in the original Ghost Recon. When you turn your dispersion increases, this means that after a fast turn you can't fire with perfect accuracy. Now days there are most sophisticated ideas such as having your weapon lag your view. You turn 180 degrees and your view moves instantly, but your weapon turns a little bit slower and so doesn't align with your view for a few moments. Call of duty actually does this if I remember correctly. Generally weapon lag is also combined with some kind of increased dispersion, or equivalent feature. I can see the creators of ArmA 2 are trying to give a model of movement that is realistic, and in many ways it is quite realistic. Unfortunately the result they've ended up with also feels clunky and awkward. This isn't because it's realistic, it's just because it's the wrong model. There are good realistic models of movement and aiming out there that don't feel even slightly awkward or unnatural and BIS could integrate them into Arma2.
  11. Well I exaggerate a little' date=' it's not quite as bad as if my soldier had [b']actually[/b] been drinking heavily ... but it wasn't that good either ... Perhaps how bad it is depends on the person. Some people are probably more tolerant of sloppy controls than others. I don't think I'm alone though, it is a common ArmA complaint, and a lot of reviewers have faulted it for the poor controls. I actually had no problem with the speed of movement at all' date=' and indeed I'm totally with you on "superfast" speed in other shooters. I much prefer the slow, cautious and thoughtful approach. I was glad that the speed in ArmA was slower than OFP, you could run far too fast in OFP. However, I'd say that's a totally different question to how responsive the controls are. And you can easily have really tight, responsive and natural feeling controls but still move at a realistic speed. I did find that the patches did help with both the performance and in fact the movement, though even by the last patch there were still quite a lot of issues. The patches definitely improved base line performance, the main problem was unpredictability. It was really hard to set your options so as to always get reasonable performance, as every so often the frame rate would plummet into the 10s. My computer is actually pretty powerful, it's a good way over the ArmA 2 recommended specs, yet I still had these kinds of issues in ArmA 1. Some people in my clan have less powerful systems, and so we felt we couldn't play it, since even I couldn't get good performance. This was probably the single biggest reason we didn't adopt it. I'm very hopeful at all the comments describing the much improved performance in ArmA 2 ... still a nicer controls system would be nice as well :) It may have been an issue with my particular CD drive causing FADE to kick in' date=' or it might not have been a FADE problem at all. That's half the problem, it's really hard to diagnose whether you've been FADED or not. A copy protection system should prevent people from pirating the game, and tell them unequivocally that is the problem. Making players constantly wonder if a particular problem is FADE related is a bad idea in my opinion. It's certainly possible to learn to work round the limitations of any system ... but that doesn't mean you should have to :) Err yeah, I walk by default and have run whilst holding the shift key :)
  12. Personally I found the controls in ArmA to be a serious weakness of the game. It was one of the reasons that my clan did not adopt ArmA as one of our played games. So there are a couple of problems with the controls in ArmA. The first, and largest problem is exactly as the original poster described: movement is tied to animation, not to key bindings. For example, if I press left, even very gently, it starts a "move left" animation which moves my character at least one foot left. This is incredibly annoying if all you are trying to do is peek out round a corner, or shuffle inside a bush so you can see through a hole. You strafe left, but you go too far, so you strafe right, but now you're back where you started so press left again. Back and forth trying to press it gently enough that you can move just the few centimetres you intended. Very, very annoying - and I've never known any other game have this problem. The other problem is less difficult to pinpoint, but basically moving and aiming your weapons felt like your virtual character had been up drinking the whole night. The movement just felt "weird" and unnatural, as if you couldn't really control your character. Another thing that may have contributed to this was the high level of momentum in game. You were constantly trying to fight against the momentum that caused you to slip and slide around. Now I'm not debating that soldiers in real life have momentum, but also they have finely tuned balance systems developed through millions of years of evolution, and refined by years of training. All I have is a monitor, a mouse and a keyboard ... so trying to deal with realistic momentum is just impossible. The game's very unpredictable performance may not have helped either, sometimes your framerate would be capped at refresh for most of the time, but then you'd look in a particular direction and start getting 10 fps ... Interestingly we didn't find the problem nearly as bad in OFP ... OFP had it's own oddities with regards to movement and control, but overall it was a lot easier to handle than ArmA. As I say, this was one of the reasons we didn't adopt ArmA. Which is a shame, because there were many things we did like about it. Whether this, and our other main issues (unpredictable performance, lack of included coop missions, seriously buggy FADE detection), have been solved in ArmA 2 is very likely to determine whether we adopt that game as well ...
×