Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Excerpt

Create a fake droid object that can be used to inspect droid attributes prior to production...

 

Syntax

Code Block
themeRDark
languagejavascript
titleWZ v3.1
linenumberstrue
var result = makeTemplate(player, name, body, prop, reserved, t1[, t2[, t3]]);

Parameters

ParameterTypeMandatoryDescriptionGame version
playerNumber(tick)The player who would be making the droid.3.2
nameString(tick)

The name the droid would have.

3.2
body

String

(tick)

The body that the droid would use.

You can quickly find the ID strings for bodies in the online guide - just click any body and look at "Body ID".

3.2
prop

String

(tick)

The propulsion the droid would use.

3.2
reserved

Null

(error)

This property is reserved for future use. Just specify null for now.

3.2

t1

String

(tick)

The first turret the droid would have.

3.2
t2

String

(error)

The second turret the droid would have.

3.2
t3

String

(error)

The third turret the droid would have.

3.2

Return value

ValueTypeDescriptionGame version
<fakeDroid>A fake
Droid objectTemplate Object
The object returned will look a bit like a droid object, but it's actually fake – the droid doesn't exist on the map, so it has no .id for example.not.3.2
nullNullNot possible for the specified player to build the droid you described.3.2
<error>ErrorSomething went terribly wrong.3.2

Example

Code Block
themeRDark
languagejavascript
titleA cyborg engineer template...
linenumberstrue
// cyborg engineer
var myEngineer = makeTemplate(
	me, // player
	"Cyb-Engineer", // name
	"Cyb-Bod-ComEng", // body
	"CyborgLegs" // propulsion
	null, // reserved
	"CyborgSpade" // turret #1
);
Div
classnotice box ping

Treat as experimental, this function (particularly its return value) could change.

Div
classbox
Availability
Status
colour
Yellow
Red
title3.2+

Requires:

  • Warzone 3.2 or above
Div
classbox
Contents

Jump to:

Table of Contents
maxLevel5

Div
classbox

See also

Related articles: