Jump to content
🛡️FORUMS ARE IN READ-ONLY MODE Read more... ×

Woodpeckersam

Member
  • Content Count

    230
  • Joined

  • Last visited

  • Medals

Everything posted by Woodpeckersam

  1. Update is good :D Thanks for that matey :D I have noticed something however... in description.ext i have this code class CfgIdentities [b][color="Red"]{[/color][/b] class Bov { name = "Lieutenant Bov"; face = "Face04"; glasses = "BlackSun"; speaker = "Male02EN"; pitch = 1.100Rnd_127x99_M2; }; class Young { name = "Sergeant Young"; face = "Face19"; glasses = ""; speaker = "Male05EN"; pitch = 0.9; }; class Roadrunner { name = "Private Roadrunner"; face = "Face25"; glasses = ""; speaker = "Male04EN"; pitch = 1.0; }; class Smith { name = "Coporal Smith"; face = "Face65"; glasses = ""; speaker = "Male09EN"; pitch = 0.85; }; class Jagger [b][color="#ff0000"]{[/color][/b] name = Corporal Jagger"; face = "Face13"; glasses = "BlueSun"; speaker = "Male07EN"; pitch = 1.05; }; }; class CfgSounds { class sniper { name = "sniper"; sound[] = {\sound\sniper.ogg, db + 0, 1.0}; titles[] = {}; }; }; The error returns is as followed... 20 E Missing } before end of file 584 E Missing } before end of file See the coloured and bold { in the code. This is not an issue at all and description.ext appears to be working fine with no errors at all, however it will confuse people who are new to scripting the description.ext. :D ---------- Post added at 10:54 PM ---------- Previous post was at 09:33 PM ---------- Oh and one more thing... When i have a unit on the map lets say i name him "ld1" it saves to mission.sqm. So i start adding all files to a new project in squint. Cool all good. Then you create a new script... i dunno summin like a dialog script or even a mission script. The you have a code such as this... ld1 groupChat "Hello Young, whats up lad?"; error returned in squint is.. Unknown variable ld1 Again this is not a major problem as i know ld1 is not a variable, it is the unit's name and i know that i can filter that out, would this be an issue? Or would the best choice be to filter it out as well as other errors that appears that we know is actually working?
  2. I'm not completely sure if this is the reason but remove faction from this _soldier = switch (faction _killed) do To _soldier = switch (_killed) do Because a switch only occurs when a value/string has been added to a variable. So if _killed = RU then do case RU: {}; If that does not work then try this... switch (_killed) do If thAt doesn't work then I may be missing out the point of your script. Maybe if you havent got the application called "Squint" go ahead and download it, then add entire mission folder to project and note down any errors in the code. Ps. I typed this on my iPod touch so that could be the reason I'm missing the point lol. ---------- Post added at 01:52 AM ---------- Previous post was at 01:39 AM ---------- _havesquint = 0; switch (_havesquint) do { case 0: { siggy = [] execWWW "http://forums.bistudio.com/showthread.php?t=105860"; siggy action ["Download Squint", siggy]; }; case 1: { siggy sideChat "I already have Squint"; sleep 6.2; WoodyUk sideChat "Cool :D I love this script to check if you got it or not!"; }; }; Of course you dont have to have it, if you dont want to.
  3. Woodpeckersam

    Toggleable Ghillie suit

    Hey F2k Sel thanks for mentioning about the weapon stuff on the other script. I incorporated it into UniSwitch.sqf and it works! Plus i added something else... current animation state of the player. If the player changes his clothes while Prone, Standing, Swimming, Crouching it will remember it and puts the uniformed unit into that same position. private ["_snipos","_rfmpos","_dir","_group","_weapons","_primweap","_magazines","_muzzles","_mov"]; _snipos = getPos sni; _rfmpos = getPos rf; _dir = getDir player; _group = group player; _weapons = ((weapons player) - (items player)); // weapons of the old unit _primweap = currentWeapon player; // primaryWeapon of the old unit _magazines = magazines player; // magazines of the old unit _mov = animationState player; titleText ["Changing Clothes", "BLACK OUT", 2]; sleep 2; sni setPos _rfmpos; rf setPos _snipos; if (player == rf) then { [rf] join grpNull; selectPlayer sni; [sni] joinSilent _group; } else { [sni] join grpNull; selectPlayer rf; [rf] joinSilent _group; }; sleep 1; player switchmove _mov; // New Unit gets the sames weapons as the old unit removeAllWeapons player; {player addMagazine _x} forEach _magazines; {player addWeapon _x} forEach _weapons; // Select the primaryWeapon player selectWeapon _primweap; // Fix for weapons with grenade launcher _muzzles = getArray(configFile>>"cfgWeapons" >> _primweap >> "muzzles"); player selectWeapon (_muzzles select 0); titleText ["Changing Clothes", "BLACK IN", 2]; player setDir _dir; exit; dont forget to credit "Cyborg11" for getting the weapons stuff to work in the other script.
  4. Woodpeckersam

    Toggleable Ghillie suit

    Not necessarily. I have made a quick script here. On a map, add 2 units. The current player and the uniform you want to switch to. The switch - to - ghillie suit guy must be WELLL out of harms way. Put him in the safest spot you can. And leave the Rifleman (the Player's original suit) where it should be, in a group or wherever. Riflman - Name: rf Sniper - Name: sni UniSwitch.sqf private ["_snipos","_rfmpos","_dir","_group"]; _snipos = getPos sni; _rfmpos = getPos rf; _dir = getDir player; _group = group player; titleText ["Changing Clothes", "BLACK OUT", 2]; sleep 2; sni setPos _rfmpos; rf setPos _snipos; if (player == rf) then { [rf] join grpNull; selectPlayer sni; [sni] joinSilent _group; } else { [sni] join grpNull; selectPlayer rf; [rf] joinSilent _group; }; sleep 1; titleText ["Changing Clothes", "BLACK IN", 2]; player setDir _dir; exit; init.sqf private ["_uniform"]; _uniform = rf addAction ["Change Uniform", "UniSwitch.sqf"]; _uniform = sni addAction ["Change Uniform", "UniSwitch.sqf"]; enableTeamSwitch false; If anyone knows how to get the "current weapon" and "current magazine" of the player, then you can set it so that every time you change your clothes, your weapon's stay the same. If you would like me to upload a mission i wouldnt mind. ---------- Post added at 10:49 PM ---------- Previous post was at 10:43 PM ---------- i changed the init.sqf script to say enableteamswitch false.
  5. Hi there im kinda stuck on something... how would i go about adding specific text/numbers to the end of a variable... an explanation... //Image you call this script... ["spawn","grpy2"] execVM "groups.sqf"; //Which loads this script... (it's made up) _markerPos = _this select 0; _groupname = _this select 1; "_groupname"+1 = createGroup east; "_groupname"+1ld = "_groupname"+1 createUnit ["TK_Soldier_SL_EP1", getMarkerPos _markerPos,[],0.8,"Lieutenant"]; As you can see i would like to allow users to input any group name they like and it would change the entire variable name throughout the script. This would be useful when you need to add loads more units... you would have to go through the list bit by bit... Here is an example of a manually created "createUnit" script that i would need to change every time i want to add a new group... private ["_grpy1","_grpy1ld","_grpy1ld2","_grpy1ld3","_grpy1ld4","_grpy1ld5","_grpy1ld6","_grpy1ld7"]; _grpy1 = createGroup east; _grpy1ld = _grpy1 createUnit ["TK_Soldier_SL_EP1", getMarkerPos "grpy1",[],0.8,"Lieutenant"]; _grpy1ld setVehicleVarName "grpy1ld" ; _grpy1ld2 = _grpy1 createUnit ["TK_Soldier_MG_EP1", getMarkerPos "grpy1",[],0.7,"Sergeant"]; _grpy1ld3 = _grpy1 createUnit ["TK_Soldier_HAT_EP1", getMarkerPos "grpy1",[],0.7,"Sergeant"]; _grpy1ld4 = _grpy1 createUnit ["TK_Soldier_LAT_EP1", getMarkerPos "grpy1",[],0.7,"Sergeant"]; _grpy1ld5 = _grpy1 createUnit ["TK_Soldier_GL_EP1", getMarkerPos "grpy1",[],0.5,"Corporal"]; _grpy1ld6 = _grpy1 createUnit ["TK_Soldier_Spotter_EP1", getMarkerPos "grpy1",[],0.5,"Corporal"]; _grpy1ld7 = _grpy1 createUnit ["TK_Soldier_MG_EP1", getMarkerPos "grpy1",[],0.5,"Corporal"]; _grpy1ld2 = _grpy1 createUnit ["TK_Soldier_HAT_EP1", getMarkerPos "grpy1",[],0.5,"Corporal"]; _grpy1ld3 = _grpy1 createUnit ["TK_Soldier_AR_EP1", getMarkerPos "grpy1",[],0.5,"Private"]; _grpy1ld4 = _grpy1 createUnit ["TK_Soldier_AT_EP1", getMarkerPos "grpy1",[],0.3,"Private"]; _grpy1ld2 = _grpy1 createUnit ["TK_Soldier_EP1", getMarkerPos "grpy1",[],0.3,"Private"]; _grpy1ld3 = _grpy1 createUnit ["TK_Soldier_EP1", getMarkerPos "grpy1",[],0.2,"Private"]; _grpy1ld4 = _grpy1 createUnit ["TK_Soldier_EP1LAT_EP1", getMarkerPos "grpy1",[],0.2,"Private"]; _null = [leader _grpy1,"basepoint1","fortify","delete:",600,"template:",2,"respawn"] execVM "scripts\upsmon.sqf"; {_x removeWeapon "NVGoggles"} forEach units leader _grpy1; then to manually change all the code for another group private ["_grpy2","_grpy2ld","_grpy2ld2","_grpy2ld3","_grpy2ld4","_grpy2ld5","_grpy2ld6","_grpy2ld7"]; _grpy2 = createGroup east; _grpy2d = _grpy2 createUnit ["TK_Soldier_SL_EP1", getMarkerPos "grpy2",[],0.8,"Lieutenant"]; _grpy2ld setVehicleVarName "grpy2ld" ; _grpy2ld2 = _grpy2 createUnit ["TK_Soldier_MG_EP1", getMarkerPos "grpy2",[],0.7,"Sergeant"]; _grpy2ld3 = _grpy2 createUnit ["TK_Soldier_HAT_EP1", getMarkerPos "grpy2",[],0.7,"Sergeant"]; _grpy2ld4 = _grpy2 createUnit ["TK_Soldier_LAT_EP1", getMarkerPos "grpy2",[],0.7,"Sergeant"]; _grpy2ld5 = _grpy2 createUnit ["TK_Soldier_GL_EP1", getMarkerPos "grpy2",[],0.5,"Corporal"]; _grpy2ld6 = _grpy2 createUnit ["TK_Soldier_Spotter_EP1", getMarkerPos "grpy2",[],0.5,"Corporal"]; _grpy2ld7 = _grpy2 createUnit ["TK_Soldier_MG_EP1", getMarkerPos "grpy2",[],0.5,"Corporal"]; _grpy2ld2 = _grpy2 createUnit ["TK_Soldier_HAT_EP1", getMarkerPos "grpy2",[],0.5,"Corporal"]; _grpy2ld3 = _grpy2 createUnit ["TK_Soldier_AR_EP1", getMarkerPos "grpy2",[],0.5,"Private"]; _grpy2ld4 = _grpy2 createUnit ["TK_Soldier_AT_EP1", getMarkerPos "grpy2",[],0.3,"Private"]; _grpy2ld2 = _grpy2 createUnit ["TK_Soldier_EP1", getMarkerPos "grpy2",[],0.3,"Private"]; _grpy2ld3 = _grpy2 createUnit ["TK_Soldier_EP1", getMarkerPos "grpy2",[],0.2,"Private"]; _grpy2ld4 = _grpy2 createUnit ["TK_Soldier_EP1LAT_EP1", getMarkerPos "grpy2",[],0.2,"Private"]; _null = [leader _grpy2,"basepoint1","fortify","delete:",600,"template:",2,"respawn"] execVM "scripts\upsmon.sqf"; {_x removeWeapon "NVGoggles"} forEach units leader _grpy2; I hurt my hand copying and pasting this script then change all the number 1's into number 2's. Notice i changed the numbers, im just demonstrating how time consuming it is to do things this way... Let me know if this is hard to understand ---------- Post added at 05:24 PM ---------- Previous post was at 05:17 PM ---------- If i could then get the time consuming work to work in just ONE script, then i could have loads of scripts with different group types... such as... Groups\LargeFortify.sqf : Contains Units from Above Groups\MediumAmbush.sqf : Contains Units from Above Except Removing 2 Sergeants, 2 Corporals's Groups\SmallPatrol.sqf: Contains A Sergeant Squad Leader, A Corporal Sniper, and 3 Private Rifleman Groups\ArtyFortify.sqf Contains 3 Spotters 1 Group Leader. (create as many as you need) Then when you need them to spawn just call either of the scripts above... or create lots of execVM's inside one script to spawn them all at the same time by calling that script inside another.... Of course these would be made to work with UPSMON.sqf
  6. lol no worries :P Can anyone else help us understand it. Im not sure if i should include it in the mission if it seems to be working fine... i always wanna take precautions.
  7. Do you understand what that code is doing? If so is it ok for you to explain it if possible? Just in case any of us run into any problems in the future.
  8. F2k Sel - How about i give you the mission i am doing (look and do what you want with it, this mission is helping me building my scripting knowledge, so it could be a full mission in the end or just a mission to help me get my scripting skills up) and check to see if mission works with UPSMON without causing surrender. Let me know if you want to check it out.
  9. That bottom code where you see leader _name thats the name of a group spawned with BIS_fnc_spawngroup. I dont know how F2k Sel gets the problem related to surrendering, but it works fine for me (see my post http://forums.bistudio.com/showthread.php?t=107435&page=2) Thanks very much for helping out with that F2k Sel. I cant be sure if it's a random problem, so i'll keep testing this out.
  10. I'll play around with the code regarding upsmon. cheers :D as for the PatrolHouse.sqf script they move to the first waypoint and then stay there... it seems as if it is not picking up the leader (leader distance marker) private ["_units","_rank","_skill","_name","_wp"]; _name = _this select 0; _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos "mcPat", east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; {_x removeWeapon "NVGoggles"} forEach units leader _name; sleep 15; _wp = _name addWaypoint [[getmarkerpos "patty1" select 0, getmarkerpos "patty1" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; waitUntil {(leader _name distance getMarkerPos "patty1") <= 15}; ld1 sideChat "Right Lads, that patrol has gone. Lets continue on"; {_x setUnitPos "auto"} foreach units ld1; {_x setBehaviour "danger"} foreach units ld1; gogo = false; sleep 5; _wp = _name addWaypoint [[getmarkerpos "patty2" select 0, getmarkerpos "patty2" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; waitUntil {(leader _name distance getMarkerPos "patty2") <= 10}; sleep 5; _wp = _name addWaypoint [[getmarkerpos "patty3" select 0, getmarkerpos "patty3" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; waitUntil {(leader _name distance getMarkerPos "patty2") <= 10}; exit; spawned groups... bah lol if only there was an easier solution. ---------- Post added at 06:18 PM ---------- Previous post was at 06:13 PM ---------- i used ld1 sidechat format ["The leader of %1 is %2",_name,leader _name] and it returned something like this.. The leader of 0 1-3-H is 0 1-3-H:1... So it doesnt even give the group a proper name... (i corrected the name it appeared as) ---------- Post added at 06:27 PM ---------- Previous post was at 06:18 PM ---------- Ah i got PatrolHouse.sqf working! :D Thanks ever so much for working with me on this F2k Sel :D Here is the working script. private ["_units","_rank","_skill","_name"]; _name = _this select 0; _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos "mcPat", east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; {_x removeWeapon "NVGoggles"} forEach units leader _name; sleep 15; leader _name move getMarkerPos "patty1"; waitUntil {(leader _name distance getMarkerPos "patty1") <= 15}; ld1 sideChat "Right Lads, that patrol has gone. Lets continue on"; {_x setUnitPos "auto"} foreach units ld1; {_x setBehaviour "danger"} foreach units ld1; gogo = false; sleep 5; leader _name move getMarkerPos "patty2"; waitUntil {(leader _name distance getMarkerPos "patty2") <= 10}; sleep 5; leader _name move getMarkerPos "patty3"; waitUntil {(leader _name distance getMarkerPos "patty2") <= 10}; exit; Now need to check how to get UPSMON to work with Spawned Units. ---------- Post added at 06:31 PM ---------- Previous post was at 06:27 PM ---------- wow i must have been blinded by the real truth... UPSMON DOES work F2k Sel :D With that suggestion you posted! :D Wooho thanks buddy!
  11. Hey again :D Thanks again for that vehicle to group code. It works a bunch! :D This is a very tough subject, i am still wondering how to pass a name to the group... i now have 2 seperate scripts. The first one is the same as above (what you have been editing) this will be for spawning groups around the town. The other one will be used for scripting specific movement of a new group. It doesnt work a great deal... the group spawns, the group moves, but getting it to work... "waitUntil leader of _name" is near a marker... it just doesnt want to know. Spawn.sqf (same you have been editing - works great as far as i know. I cant seem to tell if calling the UPSMON.sqf script actually works) private ["_marker","_type","_name","_units","_rank","_skill","_where"]; _marker = _this select 0; _type = _this select 1; _name = _this select 2; _where = _this select 3; sleep 2; {_x removeWeapon "NVGoggles"} forEach units leader _name; switch (_type) do { case "LargeFort": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1", "TK_Soldier_HAT_EP1", "TK_Soldier_LAT_EP1", "TK_Soldier_GL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_MG_EP1","TK_Soldier_AR_EP1","TK_Soldier_AT_EP1","TK_Soldier_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["LIEUTENANT", "SERGEANT", "SERGEANT", "CORPORAL", "CORPORAL","CORPORAL","CORPORAL","PRIVATE","PRIVATE","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.8,0.7,0.6,0.6,0.5,0.5,0.4,0.4,0.4,0.3,0.3,0.2]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; sleep 5; _null = [leader _name,_where,"fortify","delete:",600,"template:",2,"respawn"] execVM "scripts\upsmon.sqf"; }; case "MediumFort": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1", "TK_Soldier_GL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_AR_EP1","TK_Soldier_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["LIEUTENANT", "SERGEANT", "CORPORAL","CORPORAL","PRIVATE","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.8,0.6,0.5,0.4,0.4,0.4,0.3,0.2]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; _null = [leader _name,_where,"fortify","delete:",600,"template:",2,"respawn"] execVM "scripts\upsmon.sqf"; }; case "SmallFort": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; _null = [leader _name,_where,"fortify","delete:",600,"template:",2,"respawn"] execVM "scripts\upsmon.sqf"; }; case "SmallMecPat": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; _name = [markerPos _marker, 180, "LandRover_MG_TK_EP1", _name] call BIS_fnc_spawnVehicle; }; case "ArtyTeamFort": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","CORPORAL","PRIVATE","PRIVATE"]; _skill = [0.6,0.6,0.5,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; case "SmallPat": { _units = ["TK_Soldier_SL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; }; sleep 2; And here is PatrolHouse.sqf - not working very well... private ["_units","_rank","_skill","_name","_wp","_ld","_nameGRP","_marker"]; _name = _this select 0; _ld = leader _name; _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos "mcPat", east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; _nameGRP = [markerPos "mcPat", 180, "LandRover_MG_TK_EP1", _name] call BIS_fnc_spawnVehicle; {[_x] joinsilent _name} foreach _nameGRP; // Make Vehicle & Units Into One Group; sleep 15; _wp = _name addWaypoint [[getmarkerpos "patty1" select 0, getmarkerpos "patty1" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; _name setSpeedMode "LIMITED"; waitUntil {(_ld distance getMarkerPos "patty1") <= 10}; sleep 5; _wp = _name addWaypoint [[getmarkerpos "patty2" select 0, getmarkerpos "patty2" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; _name setSpeedMode "LIMITED"; waitUntil {(_ld distance getMarkerPos "patty2") <= 10}; sleep 5; _wp = _name addWaypoint [[getmarkerpos "patty3" select 0, getmarkerpos "patty3" select 1, 0], 0, 1]; _wp setWaypointType "MOVE"; _name setBehaviour "SAFE"; _name setSpeedMode "LIMITED"; waitUntil {(_ld distance getMarkerPos "patty3") <= 10}; ---------- Post added at 03:07 PM ---------- Previous post was at 03:03 PM ---------- edit: its confirmed... calling UPSMON in the Spawn.sqf script doesnt work at all. I dont get no error, but it doesnt work... grr and in the PatrolHouse.sqf it gives me an error for "_ld = leader _name" maybe using BIS_fnc_spawnGroup wasnt the bestest of ideas? Unless someone knows how to name units (specifically the group leader) of any created groups using BIS_fnc_spawnGroup.
  12. Hiya, Thanks for having a look at that script for me :D I'll check it out as soon as possible. Ahh apologies for not explaining in greater detail... The units I have used are the takistani army units. Maybe you don't have OA? No matter though, I'll test it using the units you have used then put the takistani units back in. :D
  13. so in that case i would have to remove anything that has a "_" before it, and remove the private[""]; command? ---------- Post added at 01:11 AM ---------- Previous post was at 01:10 AM ---------- in the main script i mean... it's fine inside spawn.sqf ---------- Post added at 01:15 AM ---------- Previous post was at 01:11 AM ---------- removing "_" doesnt work
  14. Hey there dale. Doesnt that command causes a random group to attack a position? What i would like would be to spawn loads of enemies in a village.. no problem... but working with UPSMON Script. And some other groups will be spawned specifically for depth and immersion... In the case you see above in my previous post, the player and his group sees the enemy coming towards to house they are hiding in, however i wanted the group to just walk past as if they are patrolling. Which causes the player and his group to hide, however they can be seen and if the player's team does get caught by the enemy, the mission goes off into an entirely different direction. ---------- Post added at 01:05 AM ---------- Previous post was at 12:56 AM ---------- ps i know how to make the mission go in a different direction... no big deal :D
  15. Hiya, im back again. Thanks Kylania for suggesting the BIS_fnc_spawnGroup function mate :D it works... with a small problem however. Have a look here... _null = ["mcPat","MecPatrolSmall",_patty] execVM "scripts\Spawn\Spawn.sqf"; sleep 2; pattywp1 = group _patty addwaypoint [[getmarkerpos "patty1" select 0, getmarkerpos "patty2" select 1, 0], 0, 1]; [group _patty, 1] setWaypointType "MOVE"; [group _patty, 1] setWaypointBehaviour "SAFE"; So i can call this script no problem, the group spawns... Spawn.sqf works fine :D private ["_marker","_type","_name","_units","_rank","_skill"]; _marker = _this select 0; _type = _this select 1; _name = _this select 2; {_x removeWeapon "NVGoggles"} forEach units leader _name; switch (_type) do { case "Large": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1", "TK_Soldier_HAT_EP1", "TK_Soldier_LAT_EP1", "TK_Soldier_GL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_MG_EP1","TK_Soldier_AR_EP1","TK_Soldier_AT_EP1","TK_Soldier_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["LIEUTENANT", "SERGEANT", "SERGEANT", "CORPORAL", "CORPORAL","CORPORAL","CORPORAL","PRIVATE","PRIVATE","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.8,0.7,0.6,0.6,0.5,0.5,0.4,0.4,0.4,0.3,0.3,0.2]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; case "Medium": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1", "TK_Soldier_GL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_AR_EP1","TK_Soldier_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["LIEUTENANT", "SERGEANT", "CORPORAL","CORPORAL","PRIVATE","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.8,0.6,0.5,0.4,0.4,0.4,0.3,0.2]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; case "Small": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; case "MecPatrolSmall": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; _name = [markerPos _marker, 180, "LandRover_MG_TK_EP1", _name] call BIS_fnc_spawnVehicle; }; case "ArtyTeam": { _units = ["TK_Soldier_SL_EP1", "TK_Soldier_MG_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["SERGEANT", "CORPORAL","CORPORAL","PRIVATE","PRIVATE"]; _skill = [0.6,0.6,0.5,0.4,0.3]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; case "smallPatrol": { _units = ["TK_Soldier_SL_EP1","TK_Soldier_Spotter_EP1","TK_Soldier_EP1","TK_Soldier_EP1"]; _rank = ["CORPORAL","PRIVATE","PRIVATE","PRIVATE"]; _skill = [0.5,0.4,0.4,0.4]; _name = [getMarkerPos _marker, east, _units,[], _rank, _skill,[],[],round (random 360)] call BIS_fnc_spawnGroup; }; }; The problem is though... the group doesnt move. I've tried it with the addWaypoint command, the doMove command, the move command... the group just doesnt wanna move.... Oh and calling the UPSMON.sqf script on these newly created groups doesnt work too... Can someone help? Also am i right in saying that _groups should not be declared private?
  16. Thank you will BIS_fnc_spawnGroup help what i want to accomplish? Dynamically creating groups later in game? This is for singleplayer also... edit:: SOrry i didnt mean dynamically as such i meant being able to call as many groups as i want at the same time, using 1 script for a certain type of group
  17. Well the main purpose is to be able to call the groups at a later stage, and without manually changing each code of every group using the scripts would make it much more easier. And with this would allow UPSMON to work. I would not have any idea how to call UPSMON in a group array, remove NVGoggles, change their weapons, change their skills amongst other things... you know? And individually too. edit: Sorry missed out a question of yours. Basically i got a bit peeved at the fact my teammates can see in the dark 1000 miles away, when the player cant (which is what i want) I want them to be able to communicate and give orders. I want the player not to know the enemy is there. And then at a certain point, after... lets say... patrolling a house the player has to talk to his group leader, another team member runs to the leader to tell him that he has spotted the enemy... at that point i would like the enemy to spawn and go pass the house, thus spawning other enemies in the town to fortify it or patrol it, and for the player's group to engage with. Would need about 10 large groups, 18 small groups and 5 medium groups (roughly).
  18. Hiya all! As the title says :D I am wondering how this is possible? I've been trying a couple of scripts out and they dont seem to work. Basically throughout the whole mission i would need a script that constantly loop, checking if any civillian units have died. When one of the civillians have died, i would to +1 to a variable... lets say... civii = 0; //At the start _count = forEach Units trigTown; //Name of trigger to check if (countSide Civii < _count) //If every 1 Civillian dies do the following { civii + 1; }; I cannot seem to work out the logic with current codes for this script... I haven't tested it... so i know that it dont work at all Ok so then at the end of the mission i would like some text to pop up to say... If the player kills no civilians then say the following: If the player kills at least 1 Civilians then say the following: Is there a way to do this? edit: Oops thats quite a dodgy title for this thread haha
  19. Sorry i was out all day today.... but... thanks for your help guys :D Actually theres not a problem with that at all Bon, as these civilians are out in the open, not in buildings :D But thanks for that cos it will actually helps! :D So this works, how do i lower the score of the unit? "_total" minus "_score" _total = gets the current score of the player _count = how many civilians got killed. _score = score changes every time you kill a Civilian by "_count * 20" then lowers the score by getting the current score of the unit then taking away "_score".
  20. Thanks for te speedy response :D I got a feeling that inputting variables into titletext is different from the way I did it. Haven't tested it though, however I'll research into that myself :D Thanks! ---------- Post added at 03:59 AM ---------- Previous post was at 03:38 AM ---------- titleText [format["Well done! You have killed"%_count" Civilians! Congratulations",]]; Sorry to be a nuisance but is this right?
  21. So i am assuming that this code will work in the trigger activation, provided that the trigger is set to Civilians Present and Repeatedly. {_x addeventhandler ["killed",{civ_casaulties = civ_casaulties + 1}]} foreach units thislist; How would i grab the variable from the trigger then do some maths and total it up at the end of the mission? would i need to do this.. _count = count civ_casualties; _score = _count * 20; _total = score Player; if (_count == 0) then { titleText ["Well done! You have killed"+_count+"Civilians! Congratulations", "PLAIN"] } else if (_count > 0) then { titleText ["You have killed"+_count+"Civilians! Your score will be lowered by"+_score+"percent", "PLAIN"] player addScore _total - _score; }; Can you correct me if this is totally wrong please?
  22. Woodpeckersam

    SideChat Conversations

    :D I replied Sigint :D As for the trigger systems, its a simple but messy way of doing it. I guess its preference... its up to how the creator feels how they like to do their missions. :)
  23. Hey zwobot I have it installed on Windows 7 64-bit noo problem. I don't have UAC on. Maybe try running as administrator? ---------- Post added at 12:26 PM ---------- Previous post was at 12:22 PM ---------- And make sure you have Net4 installed zwobot :D http://www.microsoft.com/downloads/details.aspx?FamilyID=9cfb2d51-5ff4-4491-b0e5-b386f32c0992&displaylang=en i cant remember if there is a specific 64-bit version of Net4. I seemed to already have that on my machine. ---------- Post added at 12:40 PM ---------- Previous post was at 12:26 PM ---------- @sbsmac Im glad that the suggestions are something there to think about. I can see that there is already intelligence on there. You seem to have great logic in programming and scripting to be able to put this sort of thing together gratz :D. About the marker thing, the logic of that should be simple? Search sqm for type=marker get name of marker and puts them all into a list. And call the list when certain commands are used. I think the same would work for units too. Get type=USMCSolder (maybe have a complete list of soldiers squint would need to search for and the ability for users to add soldier names that squint can search for (addons etc)) and if it picks any of these names up, add the names of the soldiers to a list. Then call that list when the user insert certain codes, so they can choose the soldier they want for certain things. Certain codes for example player setPos [(getpos s as soon as you type the s, it should search all units begging with an s. Same goes if you type _s it would search all variables (groups n stuff) Sorry. I dont have programming knowledge of any kind, i just think about the logic behind it. But the logic is that it should work with anything, units, vehicles, markers, triggers etc. As for an array, maybe you could have it should that when an array is called, you could get 3 boxes pop up side by side (or somewhere at the bottom/side as too many popup's would be annoying?), one of them titled "Units" second titled "_variables" and third titled "markers", and users can see exactly what they have in the missions, so in complex scripts they could just scroll through or type maybe the letter S and it filters everything out in those boxes to just show these things that has the first letter S. Oh and maybe people have the option to turn it on or off depending on how complex their scripts are. This is just ideas :) Let me know if it's hard to understand. I just seem not to be able to explain things clearly later lol. :P
  24. Woodpeckersam

    SideChat Conversations

    Hey mate, it's your choice, but if u upload the mission, could take a look for you :D
  25. Woodpeckersam

    SideChat Conversations

    Very good :D im very much like you lol. I tend to shorten things out to test them. And thank god for block commenting for making script testing 10x quicker. (just saying that, cos it seems right to say it :P) I can sense a good mission coming along :D good luck on trying to finish it b4 u leave town :D
×