createVehicle – Talk
Categories:
Lou Montana (talk | contribs) m (Text replacement - "<dd class="notedate">Posted on ([^<>]+) " to "<dd class="notedate">Posted on $1</dd> ") |
Lou Montana (talk | contribs) m (Text replacement - "Killzone Kid" to "Killzone_Kid") |
||
(2 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
::Why? You say you "believe" it should read that way. Why do you believe that? Please explain. Why does selecting pos's X and Y values, but not it's Z value make it faster? You are still passing a number as the third position array parameter. If anything your example should be slower because you are using the [[select]] command twice. --[[User:Benargee|Benargee]] ([[User talk:Benargee|talk]]) 01:48, 28 November 2015 (CET) | ::Why? You say you "believe" it should read that way. Why do you believe that? Please explain. Why does selecting pos's X and Y values, but not it's Z value make it faster? You are still passing a number as the third position array parameter. If anything your example should be slower because you are using the [[select]] command twice. --[[User:Benargee|Benargee]] ([[User talk:Benargee|talk]]) 01:48, 28 November 2015 (CET) | ||
::::I think he is suggesting that the non-array createVehicle syntax will always create vehicles at ground level whereas the array syntax won't necessarily (aka, he's talking about equivalent behaviour rather than speed). I can't verify off the top of my head if that's the case, but in response to the original question: for demonstrative purposes it is assuming the position is at ground level. --[[User:SilentSpike|SS]] ([[User talk:SilentSpike|talk]]) 14:47, 28 November 2015 (CET) | ::::I think he is suggesting that the non-array createVehicle syntax will always create vehicles at ground level whereas the array syntax won't necessarily (aka, he's talking about equivalent behaviour rather than speed). I can't verify off the top of my head if that's the case, but in response to the original question: for demonstrative purposes it is assuming the position is at ground level. --[[User:SilentSpike|SS]] ([[User talk:SilentSpike|talk]]) 14:47, 28 November 2015 (CET) | ||
::::::Parsing of array of params to the command always takes longer than a single argument. Other than that commands seem identical.[[User: | ::::::Parsing of array of params to the command always takes longer than a single argument. Other than that commands seem identical.[[User:Killzone_Kid|Killzone_Kid]] ([[User talk:Killzone_Kid|talk]]) 14:56, 28 November 2015 (CET) | ||
::I only wrote "believe" because I could be wrong just like | ::I only wrote "believe" because I could be wrong just like Killzone_Kid believed what he said was to be true. The only way to be sure is to see the source code for the createVehicle function. From what I experienced I see that the two syntax versions are not the same. The short version ignores the pos Z value and creates vehicles at ground level (Z=0) while the long version does not. Re: your question of being faster, I actually wrote that it's slower. Two selects will most likely be slower unless some compiler optimization happens in the future. --[[User:Zectbumo|Zectbumo]] ([[User talk:Zectbumo|talk]]) 17:29, 1 December 2015 (CET) | ||
::Maybe my confusion was I interpreted | ::Maybe my confusion was I interpreted Killzone_Kid's "the same" as "the same function" instead of "the same speed". I'll add a new entry focusing on equivalence.--[[User:Zectbumo|Zectbumo]] ([[User talk:Zectbumo|talk]]) 17:34, 1 December 2015 (CET) | ||
== Historic notes == | == Historic notes == | ||
<dt><dt> | |||
<dd class="notedate">Posted on Oct 18, 2009 - 05:42</dd> | <dd class="notedate">Posted on Oct 18, 2009 - 05:42</dd> | ||
<dt class="note">'''[[User:Canukausiuka|Canukausiuka]]'''<dd class="note"> | <dt class="note">'''[[User:Canukausiuka|Canukausiuka]]'''<dd class="note"> | ||
As of Arma2, this command cannot be used to create game logics [http://forums.bistudio.com/showthread.php?t=81964 (source)]. Use [[createUnit]] instead. | As of Arma2, this command cannot be used to create game logics [http://forums.bistudio.com/showthread.php?t{{=}}81964 (source)]. Use [[createUnit]] instead. | ||
<dt><dt> | |||
<dd class="notedate">Posted on August 13, 2006 - 12:18</dd> | <dd class="notedate">Posted on August 13, 2006 - 12:18</dd> | ||
<dt class="note">'''[[User:Raedor|raedor]]'''<dd class="note"> | <dt class="note">'''[[User:Raedor|raedor]]'''<dd class="note"> | ||
Using main syntax of this command sets the created vehicle not exactly at the given position, you have to [[setPos]] it there, if accuracy counts. | Using main syntax of this command sets the created vehicle not exactly at the given position, you have to [[setPos]] it there, if accuracy counts. | ||
<dt><dt> | |||
<dd class="notedate">Posted on Jan 20, 2006 </dd> | <dd class="notedate">Posted on Jan 20, 2006 </dd> | ||
<dt class="note">'''[[User:bdfy|bdfy]]'''<dd class="note"> | <dt class="note">'''[[User:bdfy|bdfy]]'''<dd class="note"> | ||
Using main syntax of this command sets the created vehicle in the nearest ''possible'' position. You can create a dozen of tanks with it - they will appear side by side. | Using main syntax of this command sets the created vehicle in the nearest ''possible'' position. You can create a dozen of tanks with it - they will appear side by side. |
Latest revision as of 14:48, 12 March 2024
KillZone Kid mentions ' "vehclass" createVehicle pos is the same if not faster than createVehicle ["vehclass", pos, [], 0, "NONE"] ' but this is not entirely true. I believe it should read: "vehclass" createVehicle pos is the same if not faster than createVehicle ["vehclass", [pos select 0, pos select 1, 0], [], 0, "NONE"] --Zectbumo
- Why? You say you "believe" it should read that way. Why do you believe that? Please explain. Why does selecting pos's X and Y values, but not it's Z value make it faster? You are still passing a number as the third position array parameter. If anything your example should be slower because you are using the select command twice. --Benargee (talk) 01:48, 28 November 2015 (CET)
- I think he is suggesting that the non-array createVehicle syntax will always create vehicles at ground level whereas the array syntax won't necessarily (aka, he's talking about equivalent behaviour rather than speed). I can't verify off the top of my head if that's the case, but in response to the original question: for demonstrative purposes it is assuming the position is at ground level. --SS (talk) 14:47, 28 November 2015 (CET)
- Parsing of array of params to the command always takes longer than a single argument. Other than that commands seem identical.Killzone_Kid (talk) 14:56, 28 November 2015 (CET)
- I think he is suggesting that the non-array createVehicle syntax will always create vehicles at ground level whereas the array syntax won't necessarily (aka, he's talking about equivalent behaviour rather than speed). I can't verify off the top of my head if that's the case, but in response to the original question: for demonstrative purposes it is assuming the position is at ground level. --SS (talk) 14:47, 28 November 2015 (CET)
- I only wrote "believe" because I could be wrong just like Killzone_Kid believed what he said was to be true. The only way to be sure is to see the source code for the createVehicle function. From what I experienced I see that the two syntax versions are not the same. The short version ignores the pos Z value and creates vehicles at ground level (Z=0) while the long version does not. Re: your question of being faster, I actually wrote that it's slower. Two selects will most likely be slower unless some compiler optimization happens in the future. --Zectbumo (talk) 17:29, 1 December 2015 (CET)
- Maybe my confusion was I interpreted Killzone_Kid's "the same" as "the same function" instead of "the same speed". I'll add a new entry focusing on equivalence.--Zectbumo (talk) 17:34, 1 December 2015 (CET)
- Why? You say you "believe" it should read that way. Why do you believe that? Please explain. Why does selecting pos's X and Y values, but not it's Z value make it faster? You are still passing a number as the third position array parameter. If anything your example should be slower because you are using the select command twice. --Benargee (talk) 01:48, 28 November 2015 (CET)