summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Items.c4d/Distributor.c4d/Script.c2
-rw-r--r--Items.c4d/Extractor.c4d/Script.c14
-rw-r--r--Items.c4d/Filler.c4d/Script.c4
-rw-r--r--Items.c4d/Utility.c4d/Script.c20
4 files changed, 20 insertions, 20 deletions
diff --git a/Items.c4d/Distributor.c4d/Script.c b/Items.c4d/Distributor.c4d/Script.c
index e46c33a..6ee7cf4 100644
--- a/Items.c4d/Distributor.c4d/Script.c
+++ b/Items.c4d/Distributor.c4d/Script.c
@@ -94,7 +94,7 @@ func GetRetrievableObjects(object requester, bool produce)
{
if(GetIndexOf(id, IDs) == -1)
{
- IDs[GetLength(IDs)] = id;
+ IDs[] = id;
}
}
}
diff --git a/Items.c4d/Extractor.c4d/Script.c b/Items.c4d/Extractor.c4d/Script.c
index 05a1fc6..7dddbc8 100644
--- a/Items.c4d/Extractor.c4d/Script.c
+++ b/Items.c4d/Extractor.c4d/Script.c
@@ -120,9 +120,9 @@ func AddQueue(array args)
}
else
{
- produceQueue[GetLength(produceQueue)] = args;
+ produceQueue[] = args;
}
-
+
if(GetLength(produceQueue) == 1 || !GetCommand(worker))
{
ContinueQueue();
@@ -153,7 +153,7 @@ func ShowQueue()
for(var i = 1; i <= GetLength(produceQueue); ++i)
{
var id = produceQueue[i] && produceQueue[i][0];
-
+
if(lastID == id)
{
++cnt;
@@ -174,7 +174,7 @@ func ShowQueue()
}
cnt = 0;
}
-
+
lastID = id;
}
if(i < GetLength(produceQueue))
@@ -264,7 +264,7 @@ func GetProducableIDs()
{
if(GetDefCollectible(type) && GetHomebaseMaterial(plr, type) && GetWealth(plr) >= GetValue(0, type, attached, plr))
{
- ret[GetLength(ret)] = type;
+ ret[] = type;
}
}
}
@@ -276,7 +276,7 @@ func GetProducableIDs()
{
if(attached->~IsProducerOf(worker, type))
{
- ret[GetLength(ret)] = type;
+ ret[] = type;
}
}
}
@@ -306,7 +306,7 @@ func SensorCallbacks()
{
for(var id in part)
{
- ret[GetLength(ret)] = [Format("$SendObjectType$", GetName(0, id)), BindCallback("SendObjectThroughTube", [Bind(id), 2]), id];
+ ret[] = [Format("$SendObjectType$", GetName(0, id)), BindCallback("SendObjectThroughTube", [Bind(id), 2]), id];
}
}
}
diff --git a/Items.c4d/Filler.c4d/Script.c b/Items.c4d/Filler.c4d/Script.c
index 7459a08..4288c54 100644
--- a/Items.c4d/Filler.c4d/Script.c
+++ b/Items.c4d/Filler.c4d/Script.c
@@ -64,13 +64,13 @@ func SensorCallbacks()
var ret = [["$RetrieveObject$", BindCallback("RetrieveObjectThroughTube", [1, 2])]];
for(var id in GetRetrievableIDs())
{
- ret[GetLength(ret)] = [Format("$RetrieveObjectType$", GetName(0, id)), BindCallback("RetrieveObjectThroughTube", [Bind(id), 2]), id];
+ ret[] = [Format("$RetrieveObjectType$", GetName(0, id)), BindCallback("RetrieveObjectThroughTube", [Bind(id), 2]), id];
}
for(var part in GetRetrievableIDs(true))
{
for(var id in part[1])
{
- ret[GetLength(ret)] = [Format("$RetrieveObjectType$", GetName(0, id)), BindCallback("RetrieveObjectThroughTube", [Bind(id), 2]), id];
+ ret[] = [Format("$RetrieveObjectType$", GetName(0, id)), BindCallback("RetrieveObjectThroughTube", [Bind(id), 2]), id];
}
}
return ret;
diff --git a/Items.c4d/Utility.c4d/Script.c b/Items.c4d/Utility.c4d/Script.c
index 48cdc7c..6e44f7e 100644
--- a/Items.c4d/Utility.c4d/Script.c
+++ b/Items.c4d/Utility.c4d/Script.c
@@ -22,7 +22,7 @@ func AttachMenu(object caller, bool allowFloating)
var targets = FindObjects(Find_AtPoint(), Find_Exclude(caller), Find_Exclude(this), AttachObjectCondition(caller));
if(allowFloating)
{
- targets[GetLength(targets)] = [0, "$AttachWall$", GetID()];
+ targets[] = [0, "$AttachWall$", GetID()];
}
return caller->~CreateSelectionMenu("AttachEntry", targets, GetID(), "$SelectTarget$", this);
}
@@ -47,7 +47,7 @@ func Attach(object target) // TODO: maybe use scripted Attach instead; check if
{ // WARNING: needs an action with the name "Attach", the Procedure "ATTACH" and an AbortCall of "Detached"
SetVertex(AttachVertex(), VTX_X, GetX(target) - GetX() + GetVertex(0, VTX_X, target), this, VTX_SetPermanentUpd);
SetVertex(AttachVertex(), VTX_Y, GetY(target) - GetY() + 5 + GetVertex(0, VTX_Y, target), this, VTX_SetPermanentUpd);
-
+
SetAction("Attach", target);
SetActionData(AttachVertex() << 8);
}
@@ -95,14 +95,14 @@ func GetRetrievableIDs(bool produce)
{
if(GetIndexOf(id, IDs) == -1)
{
- IDs[GetLength(IDs)] = id;
+ IDs[] = id;
}
}
}
-
+
if(produce)
{
- produceIDs[GetLength(produceIDs)] = [line->GetLineEnd(this), line->GetRetrievableObjects(this, true)];
+ produceIDs[] = [line->GetLineEnd(this), line->GetRetrievableObjects(this, true)];
}
}
if(produce)
@@ -121,13 +121,13 @@ func GetRetrievableIDs(bool produce)
{
if(GetIndexOf(id, parts) == -1 && GetIndexOf(id, IDs) == -1)
{
- part[GetLength(part)] = id;
- parts[GetLength(parts)] = id;
+ part[] = id;
+ parts[] = id;
}
}
if(GetLength(part) > 0)
{
- ret[GetLength(ret)] = [produceIDs[i][0], part];
+ ret[] = [produceIDs[i][0], part];
}
}
}
@@ -247,7 +247,7 @@ func GetSendableIDs(bool production)
{
if(GetIndexOf(GetID(obj), IDs) == -1)
{
- IDs[GetLength(IDs)] = GetID(obj);
+ IDs[] = GetID(obj);
}
}
}
@@ -261,7 +261,7 @@ func GetSendableIDs(bool production)
{
if(GetIndexOf(id, IDs) == -1)
{
- ret[GetLength(ret)] = id;
+ ret[] = id;
}
}
}