Jump to content

moddero

Member
  • Content Count

    10
  • Joined

  • Last visited

  • Medals

Community Reputation

1 Neutral

About moddero

  • Rank
    Private
  1. Uhmm seems it can be done...both messages were shown at the screen. My name and the other hint. however this does no work as i intended _des1 = allunits + vehicles; { if (_x iskindof "AllVehicles" &&(alive _x)) then { _groupi=nearestObjects [_x, ["Man","Man"], 300]select 1 ; }; { _s=side _x; hintSilent format ["%1",_s]; switch (_s) do { case west: { _blufi=_blufi+[_x];hintsilent"blufor detected";}; case east: { _redie=_redie+[_x]; }; }; }forEach [_groupi]; } forEach _des1; its shows me: 0xcb866c when it should be one of the sides...(west,east...) and if i place hintSilent format ["%1",_groupi]; showns "ANY"(inside the 2º "foreach" ,if inside the 1º it shows all the groups...one each time) P.S.:I am trying to use the "-showScriptErrors" comand but i had some problems activating it (I thought it was already activated,but not showing any errors),and now...trying to see the scripts errors throught te ones from the addons i have active...i should probably try it without the addons activated,but i want the script to be compatible with them...
  2. ty...now works fine...is there any way to force it only to run on certain scripts??i am using lot of addons...and some of them have errors...so it's stuck showing the addon errors and never shows my script errors...
  3. paste error , this it's the real: "C:\Archivos de programa\Bohemia Interactive\arma2oa.exe" -mod=@mios;@lingor;@SGMODbeta;@CBA;@mar_2MAW;@CHN_P redator;@cicada1.2;@PLR;@bracer;@Klurs_A1;@I44CO;@ASG; -showScriptErrors; -name=moddero I also have tried this: "C:\Archivos de programa\Bohemia Interactive\arma2oa.exe" -mod=@mios;@lingor;@SGMODbeta;@CBA;@mar_2MAW;@CHN_P redator;@cicada1.2;@PLR;@bracer;@Klurs_A1;@I44CO;@ASG;-showScriptErrors;-name=moddero it keeps loading the addons and the profile but not showing any scripts mistakes...do i have to place anything more inside the script or it should work just with that?
  4. i have seen a warfare base on 1944 mod quite similar to benny's warfare...i played it on a team deadly server...(No longer active). I am also trying to create a warfare from some addons i have found... 1º from a tv-movie and the 2º are the nimitz carrier ,the f-18,the kuznestov and the su-33. Right now i am busy with smaller scripts so i have not think how to implement all into a warfare mission... The scripts are: surrender-capture(WIP),defense teams(finished) and stun weapons(finished) for the 1º mission ,and rearmpoint(not yet finished due to bugs with the addons) and realistic-wounds for the second(the last one for both missions actually) . Anyway i have thought about mixing it with BI warfare(i found some warfare example files at armaholic) using somehow the bis_coin module but i think its too complicated...plus i would like to have more than 2 variables(money ,suplies,points for example),plus i dont really know how the suplies really works...(not sure if i can add it to anything but cities) I also have been testing with Spon money from ArmA and i had quite succesful results.(you can also download it from armaholic).So i will probably use this option rather that the bi warfare module. For being able to open the mission with arma2 i opened the sqm and changed the units classname and the map... the mission works fine but no paychecks...and no option to open the dialog...but if you scroll you'll see somewhere the bar does not light up anything... there its where you should open it. Anyway maybe would be easier for you to just take the script...i took the whole mission just in case it had any triggers that needed to be set up for the mission to work...and i think it does... don't remeber exactly but i am sure needs at least 2 for starting 2 sqf's.
  5. I have the following shortcut's target line: "C:\Archivos de programa\Bohemia Interactive\arma2oa.exe" -mod=@mios;@lingor;@SGMODbeta;@CBA;@mar_2MAW;@CHN_Predator;@cicada1.2;@PLR;@bracer;@Klurs_A1;@I44CO;@ASG;-showScriptErrors; -name=moddero but no errors show up at the screen...
  6. I dont know if this what you're locking foor its pretty simple but anyway... add the following line to the units init you want to have the action: returnloset= this addAction ["return", "youname.sqf"]; then name this script same you named it before youname.sqf _s = _this select 0; _caller = _this select 1; _id = _this select 2; ; _thebest=leader _s _lost = _s _lost setpos (getPos _thebest);
  7. moddero

    Clear house script

    what does the hints shows? try this: _building = cursorTarget select _x; _buildingpositions = _building buildingpos; where _x its the number where you desired value it's(starting for 0) example(never tried so i dont know what will it show up ,so it's just for example) [villa_7,78890,56,24,0] if you want the classname would be select 0... if you want the second number select 1...
  8. hello,thanks for answering. The second script its just for pointing one fact (reduced version)that local variables cannot be called in the same script from outside the foreach comand...however this works: 1=allunits; { _me=player; hintSilent format ["%1",_me]; }; }foreach 1; and this one too my problem would be with this: 1=allunits; { _me=player; { //exactly here its my problem hint"this message never shows up"; hintSilent format ["%1",_me]; }; }foreach _x; }foreach 1; I need to run a 2º search whitin all the members of the group for detecting the sides of each one and compare if the number of one side its 60% higher than the other (switch with case west,case east,case resistance and switch case blufir*1.6<redie ,case redie*1.6<blufir) ah i forgot this also works: 1 = allunits + vehicles; { if (_x iskindof "AllVehicles" &&(alive _x)) then { _group=nearestObjects [_x, ["Man","Man"], 300]select 1 ; hintSilent format ["%1",_group]; }; //hitsilent because it will be keep apearing till you end the mission and would be anoying...and because it lags a lot playing so many"dings" }foreach 1; Anyway my question should be: Can i use the "foreach" comand within itslef? and if the answer its not... how could i create a script wich do what i want it to do. For example sending the message"we surrender" when a certain group of units are outnumbered by an enemy squad ,60%higher withing a range of 300 meters(i don want the whole side to surrender just the small group) Regarding the variable name i am agree with changing it but since it works everytime i try it i really don't care too much...in fact i did not named that way..i picked it up from USPMON script same as the switch for detecting the side (and in the spoiler script, the handle damage from celery scripts). USPMOM has a surrender script but it makes all the units from one surrender(they put their hands and you can force them to join your group...may take a while tought...since they sometimes send you...) I JUST WANT A SMALL GROUP WITHIN 300 M RADIUS! but the only way i have think of programing it, its by this way... maybe using while... or something...i dont know...thats why i need help...i have no more ideas...:(
  9. have you tested if the script runs?? does the loop starts? you said none of the waypoints show up ,not even a first one? and a couple more questions... i am not sure of having understood the script...are the waypoints created at random places?? and if they are,doesn't the mission lag? If everything is as i supose it's, i think the problem its with the creation of the waypoints. I think it cannot create from so few data... anyway i am not sure how adding an specific zone for the waypoints to create...i think it would be too hard...if its only for flying a plane in some sort of patrol and sometimes engange with some spawned vehicles i'd place some makers, define the units and vehicles you want there(or the probability)and use the random comand for picking one marker as a waypoint.
  10. I wish to create a script wich makes an specific number of units(all from the same side) "surrender" to the enemy side(just for blufor and opfor)when they are outnumbered by 60% those units should be inside 300 meters radius circle from the enemy(any unit). This is what i have come up whit: 1 = allunits + vehicles; { if (_x iskindof "AllVehicles" &&(alive _x)) then { _s = side _x; _group=nearestObjects [_x, ["Man","Man"], 300]select 1 ; switch (true) do { case (blufisur): { while(true)do { _puntirank = rating _x; _rankm = rating _redinmax; if (_puntirank>_rankm) exitWith {_redimax=_x-_redinmax;}; }; blufi join (group _redinmax); }; }; case (redisur): { while(true)do { _puntiranki = rating _x; _rankj = rating _blufinmax; if (_puntiranki>_rankj) exitWith {_blufinmax=_x-_blufinmax;}; }; redie join (group _blufinmax); }; }; { //i have placed this hint to see if this paragraph runs,here it's where i have problems, i have never seen one of this hints in game... hint"start"; switch (_s) do { case west: { _blufi=_blufi+[_x];hint "blufor detected";hintSilent format ["%1",_blufi]; }; case east: { _redie=_redie+[_x]; }; case resistance: { _nocolour=_nocolour+[_x]; }; }; switch (true) do { case ((_blufi*1.6)>(_redie)): { blufisur=true; hint "SURRENDER!!!"; }; case ((_redie*1.6)>(_blufi)): { redisur=true; }; }; }forEach group; } forEach 1; }; As i mark in the code i have problems when using the 2º for each inside the first one( for each 1 ;for each group;)the hints i placed never show up and the units never surrender because no group side its ever detected... is it not posible to use the comand for each 2 times at the same script? or calling it inside another?or both? i have checked the information regarding the comand and i found nothing useful for my problem... P.S.:I noticed that local variables does not work outside the comand ;example: 1=allunits; { _me=player; }foreach 1; hintSilent format ["%1",_me]; }; does not show the player unit... i dont know if it's also the same with all the variables... i tried sometimes with globals and it works, but sometimes not.(blufisur,redisur):confused:
×