Jump to content

Grumpy Old Man

Member
  • Content Count

    4333
  • Joined

  • Last visited

  • Medals

Everything posted by Grumpy Old Man

  1. Grumpy Old Man

    What was your Gateway Arma?

    First contact with the arma franchise has been through day-z. Enjoyed the hell out of it during the early days, was quite an experience meeting other players, fending off those zombies while trying to gather supplies, get armed and on top of that somehow trying to get a grasp of the gritty A2. The more popular day-z became, the more uninteresting it became to me, since most servers got flooded by folks just interested in shooting each other (way better gamemodes out there for that kind of playstyle). Then I played my fair share of Takistan life in a rather small but active server, north government vs southern rebels, oh the times... After that I discovered the editor and slowly descended into the depths of .sqf scripting. I have looked upon all sqf has to hold of horror, and even the skies of spring and flowers of summer must ever afterward be poison to me. Cheers
  2. Grumpy Old Man

    Need Help Making Simple Money System

    Might find this useful: Already checks if the transaction drops below 0 and if the player can actually carry the item, if any of those fails the transaction won't happen. Pretty basic and easy to build upon. Cheers
  3. Grumpy Old Man

    scripts ramdon remoteExec

    Check the quotation marks. Cheers
  4. Don't post an entire page containing of 2-3 lines of minor, already solved issues every 20 minutes, instead condense it so people can figure out at first glance what's going on. Will most likely lead to more replies/help. This forum is far from dead, folks simply don't post every 5-15 minutes like it's some social messaging app. Try stuff out, if extensive search engine usage and rummaging through similar topics and the wiki aren't providing a solution, then it's time to post, forum etiquette. To have remoteExec send to all players while being local MP and dedicated server compatible simply use [0,-2] select isDedicated as second parameter, so it will be executed on every client except the server in dedicated environment, in locally hosted MP (where the hosting server has a player) it will be executed accordingly. Cheers
  5. Works out neat, if a bit robotical. Why waste a single bullet when you can throw ordnance worth 5digits+ on a single unit, heh... Cheers
  6. Grumpy Old Man

    [Release] GOM_CB - Carpet Bombing V1.1

    Triggers don't have an init field, you need to put it inside the triggers "On Activation" field. Also make sure the trigger fires by adding this line: hint "Trigger fired!"; If the hint doesn't show, then the trigger doesn't fire. Cheers
  7. _i is simply a variable name, in this case it's used by the for loop to hold the current iteration and increases each iteration by the amount chosen by step (default by 1). for "_i" from 0 to 1 do { systemchat str _i; }; //will print //0 //1 for "_i" from 0 to 100 step 10 do { systemchat str _i; }; //will print //0 //10 //etc. You can name it whatever you want, as long as the same variable doesn't exist already. Might as well be _bananas, it doesn't matter. For practical purposes it's common to use _i though. Cheers
  8. As long as AI behavior will override most script commands (try to turn on vehicle lights at night outside of "SAFE" AI behavior etc.) and other AI components remain inaccessible through scripting, it's not really worth investing the time. Cheers
  9. If you're already on the .sqf side of things, there's barely any reason to keep using triggers. Cheers
  10. Depends on what you want to achieve, you seem confused considering your usage of remoteExecs with isServer checks from inside init.sqf. Cheers
  11. Grumpy Old Man

    prevent AI from flanking

    Simplest solution might be to just block the tunnel entrance. Other than that you'd probably need to make the AI advance manually and disable respective features such as enableAttack etc. Cheers
  12. Grumpy Old Man

    Accurate moving

    Both image and snippet are not mine, the snippet used was most likely by his highness @killzone_kid Cheers
  13. Grumpy Old Man

    No Sound with Explosion

    Vehicles should play an explosion sound, even when using setDamage 1 command, is this a vanilla vehicle or mod asset? Cheers
  14. Grumpy Old Man

    Accurate moving

    Pathfinding is perfectly fine, it's the (for some reason extremely generous) bounding boxes that cause what you described. Outer lines are from boundingBox, inner lines are from boundingBoxReal. Guess we need boundingBoxForReal... Try moving an AI close to this one. Cheers
  15. Grumpy Old Man

    Accurate moving

    They always move within 10cm of where I order them. Cheers
  16. This was a bit of a headscratcher for me back in the days, since the hit eventhandler ceases to work when a unit is set to allowDamage false. Might as well rename that command to allowGettingHit.. This will do the trick, allowDamage is not needed, the damage upon each hit (even when a bullet hits multiple selections) will be 0 while still allowing the hit eventhandler to work: test addEventHandler ["Hit",{ params ["_unit", "_source", "_damage", "_instigator"]; _hits = _unit getVariable ["TAG_fnc_hits",0]; _hits = _hits + 1; _unit setVariable ["TAG_fnc_hits",_hits]; hint format ["%1 has been hit %2 times",name _unit,_hits]; }]; test addEventHandler ["HandleDamage",{0}]; Cheers
  17. Grumpy Old Man

    Damaged car rendering

    I'm usually eager to rant on some decisions regarding BI naming conventions but from the looks of it the config contains all possible materials, while the getObjectMaterials command only returns currently used ones. This wouldn't explain the empty damage textures config though. Maybe the engine is handling stuff differently, similar to this (if related at all) there's also no way to get an objects mass without spawning it and using the getMass command. No mass config entry exists. Cheers
  18. Grumpy Old Man

    Damaged car rendering

    Here's what I used: _vehicle = this; _state = 1; _type = typeOf _vehicle; _selections = getArray (configfile >> "CfgVehicles" >> _type >> "hiddenSelections"); if (_selections isEqualTo []) exitWith {diag_log "vehDamage: No selections found.";false}; _mats = getArray (configfile >> "CfgVehicles" >> _type >> "Damage" >> "mat"); _textures = getArray (configfile >> "CfgVehicles" >> _type >> "Damage" >> "tex"); if (_type isKindOf "CAManBase") then { _mats = getArray (configfile >> "CfgVehicles" >> _type >> "Wounds" >> "mat"); _textures = getArray (configfile >> "CfgVehicles" >> _type >> "Wounds" >> "tex"); }; _debug = []; _hasMats = !(_mats isEqualTo []); _hasTexs = !(_textures isEqualTo []); if (!_hasMats AND !_hasTexs) exitWith {diag_log "vehDamage: No mats and textures found.";false}; _count = 0; for "_i" from 0 to ((count _selections -1) * 3) step 3 do { if (_hasMats) then { _mat = _mats select (_i + _state); _debug pushback (_i + _state); _debug pushback _mat; _debug pushback "----"; _vehicle setObjectMaterialGlobal [_count,_mat]; }; if (_hasTexs) then { _tex = _textures select (_i + _state); _debug pushback (_i + _state); _debug pushback _tex; _debug pushback "----"; _vehicle setObjectTextureGlobal [_count,_tex]; }; _count = _count + 1; }; true This was made quite some time ago so maybe stuff changed, but was no problem to make a damaged vehicle look like new, even with hull damaged to 0.8. With this you can also make a healthy infantry unit have blood all over the place. Just play with the _state number (up to 3 if I recall correctly). Cheers
  19. Grumpy Old Man

    Damaged car rendering

    Dig through the config for the regular vehicle textures, on the damaged vehicle simply setObjectTexture to the default one, so even when heavily damaged it will look like a pristine editor placed vehicle. Cheers
  20. Grumpy Old Man

    [Release] GOM - Vehicle Tuning V1.01

    Cost functionality isn't yet implemented. Best add this function to one player only and have him offer his services for cash. Cheers
  21. You put it in the init field, it needs to be in the expression field as stated above. The tooltips basically give it away. Cheers
  22. Grumpy Old Man

    Teleport to Vehicle anyone?

    Depends on how you're applying the addAction, shouldn't multiplicate on its own. Cheers
  23. Grumpy Old Man

    Respawn in airborne vehicle

    setSpeedMode only affects groups or units/manned vehicles, won't have any effect on empty vehicles. Shouldn't be needed, since the proper syntax of createVehicle already spawns the plane with engines on (without having to spool up) and with a healthy forward momentum: _plane = createVehicle ["B_plane_CAS_01_dynamicLoadout_F", (getPosATL player vectorAdd [0,0,100]), [], 0, "FLY"]; player moveInAny _plane; Should be all that's needed (with adjusted spawn position of course). Cheers
  24. Weird approach, why not just use a simple isClass check inside the respective functions to see if a certain mod is loaded? Compatibility for certain mods can be implemented by the script author, so you already know which classes (i.e. unit/item spawning) will be used, simply add them to an array, then use an isClass check for further procedures. Cheers
  25. Grumpy Old Man

    Change mass when sling

    Daytime doesn't matter. Coffee does. Cheers
×