Jump to content
Sign in to follow this  
snkman

Editing/Scripting

Recommended Posts

Well so far there is no Editing/Scripting section so i will post it here.

Game Logic:

Looks like Game Logics can not moved ( setPos ) any longer.

I do used Game Logics to create a move point.

Example:

_group = _this select 0;

_logic = "Logic" createVehicle [0, 0, 0];

_logic setPos (getPos player);

_group move (getPos _logic);

setCaptive:

Units which do use the setCaptive command are now on side civilian.

Example:

player setCaptive True;

if (side player == civilian) then {hint "Damn it im supposed to be a soldier!"};

Share this post


Link to post
Share on other sites

I don't like the thought that you're using game logics for this.

Use markers or "H (invisible)" instead.

Btw.. Check out locations. Might be exactly what you're trying to do with game logics.

http://community.bistudio.com/wiki/createLocation

Also, I don't get why you want to do:

_group = _this select 0;

_logic = "Logic" createVehicle [0, 0, 0];

_logic setPos (getPos player);

_group move (getPos _logic);

When you can just do

_group doMove getPos player

or

_group move position player

?????

PS: I prefer doMove as it will make the unit move to the position, where as move creates a waypoint for the unit. (Unless of course, you're building a path)

Edited by MulleDK19

Share this post


Link to post
Share on other sites

Yes the part with the logic was just an example.

Of course i would never do something like that. :D

Well i use addWaypoint instead of a logic.

Share this post


Link to post
Share on other sites
Yes the part with the logic was just an example.

Of course i would never do something like that. :D

Well i use addWaypoint instead of a logic.

Why do you need to create anything to move them?

Why not just move them with doMove?

Share this post


Link to post
Share on other sites

Becouse i need a object that is setPost with a random value every time i call it.

And then let the group move to it.

Share this post


Link to post
Share on other sites
Becouse i need a object that is setPost with a random value every time i call it.

And then let the group move to it.

Why not just:

_group doMove [random 3000, random 3000, 0]

?????

Share this post


Link to post
Share on other sites
Becouse i need a object that is setPost with a random value every time i call it.

And then let the group move to it.

Can't you use a waypoint for that?

Strange that gamelogics can't be moved though.

Share this post


Link to post
Share on other sites

Is there a way to see the list of possible respawn options with A2? You know, like bird, base,group, etc?

Share this post


Link to post
Share on other sites

Moving to the shiny new editing/scripting forum :)

Share this post


Link to post
Share on other sites
Why not just:

_group doMove [random 3000, random 3000, 0]

?????

Well i know all thouse way's how to let a unit/group move from A to B it wasn't a request to tell me how to slove this problem.

The only reason, why i started this thread was to let the community know about some new command behaviours.

Helicopter Landing:

The command "Get In" was changed to "GETIN"

I think its the same goes for "GET OUT" use "GETOUT" instead.

Edited by SNKMAN

Share this post


Link to post
Share on other sites

Thanks for the reports. These "Differences from Arma" tips are very useful. Keep them coming.

Share this post


Link to post
Share on other sites

Can someone who got the game test if the commands getMarkerShape and getTriggerArea exist ? Thanks

Share this post


Link to post
Share on other sites
Can someone who got the game test if the commands getMarkerShape and getTriggerArea exist ? Thanks

Sorry, but the answer seems no on both accounts.

Edit: There is a command MarkerShape and TriggerArea, so the answer is yes after all :)

Edited by HitmanFF

Share this post


Link to post
Share on other sites

Warning!

In .sqf a missing ";" at the end of a line will not be reported/dispayed as an error.

The script simply will stop working from this line.

findCover:

Looks like the command findCover do not work any longer.

Edited by SNKMAN

Share this post


Link to post
Share on other sites

I think it's just markerShape (without 'get' prefix) & triggerArea based on extracted list on Biki. (Edit: Didn't see your edit.)

The missing semi-colon ';' was sometimes the same in Arma too.

Edited by Dr_Eyeball

Share this post


Link to post
Share on other sites

Sorry to add to the pedantry, but you can't use this any more:

_logic = "Logic" createVehicle [0, 0, 0];

In A2 you have to use:

_logic = "Logic" createVehicleLocal [0, 0, 0];

or

_logic = (createGroup sideLogic) createVehicle ["logic", [0, 0, 0], [], 0, "NONE"]

EDIT: and, what I forgot to say, is that I've had no problems setPosing either type.

Edited by Spooner

Share this post


Link to post
Share on other sites

Yes you are right Spooner. ;)

Thanks for pointing that out.

Well another BIG problem i found:

If you have errors in your syntax then there is no error message showing, that something is wrong!

Example:

if alive player) then
{
    hint "player is alive";
};

Now you should get a error message, telling you that a "(" is missing in front of alive.

But there is nothing shown.

Scripts simply stops working from the point the error was made.

Same goes to every other kind of syntax error.

Share this post


Link to post
Share on other sites

Yeah, I think that came in with 1.01beta (bad, bad idea if it isn't a bug!). Until they fix it, use a log viewer (with tail), like LogExpert, to watch what is happening in RPT!

Share this post


Link to post
Share on other sites

When I played the MP campaign with a friend in 1.00, there were literally 100's of script error messages popping up, so I assume BIS just disabled error output in the game to make it look like they fixed a lot of error in the campaign.

Thanks for suggesting LogExpert there spooner :)

Share this post


Link to post
Share on other sites
When I played the MP campaign with a friend in 1.00, there were literally 100's of script error messages popping up, so I assume BIS just disabled error output in the game to make it look like they fixed a lot of error in the campaign.

Thanks for suggesting LogExpert there spooner :)

Haha, yeahh that would make absolutely sense! :rolleyes::j: :D

Share this post


Link to post
Share on other sites

@Mike84: That makes frightening sense. Make people think things were fine while simultaneously make it harder for community scripters...

Missing error messages ticketed at DH.

Share this post


Link to post
Share on other sites

Concerning mp game lobby, are there more than 2 parameters available to set up or still the same ?

Do commands addMagazineCargo, addWeaponCargo, clearMagazineCargo and clearWeaponCargo have global effects now ?

Share this post


Link to post
Share on other sites

The example missions still put lots of actual parameters into just 2 physical parameter boxes, so that doesn't sound promising.

Share this post


Link to post
Share on other sites

Looks like creating the Logic works fine, Spooner. I can't seem to put them in vehicles anymore, though, like in ArmA1? There goes my dummy model for filling up/disabling vehicle slots..

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×