Reticle Type in MapObj()??

Have modding questions or discovered something new? Post here.
Post Reply
User avatar
Magnos
Half Track
Half Track
Posts: 61
Joined: Sun Dec 16, 2018 1:27 pm
Egypt

Reticle Type in MapObj()??

Post by Magnos »

what is ReticleType("Object"); in MapObj use? idk
User avatar
TommyCD1
Moderator
Moderator
Posts: 1146
Joined: Tue Jun 04, 2013 8:55 am
Location: East Coast
Contact:
United States of America

Re: Reticle Type in MapObj()??

Post by TommyCD1 »

That defines the HUD elements a unit uses when you mouse over it.
There are three different types:
  • Small
  • Large
  • Vehicle
The types 'Small' and 'Large' are assigned automatically by the game dependent on if the objects godfile uses a driver. (As in can the unit move around or does it zip to the map.)
The third type 'Vehicle' can be assigned manually instead of using the 'Small' type. It is the same as the small type, except it will always display two corners on the health bar when owned by someone else.
Attachments
vehicle.png
ReticleType("Vehicle");
vehicle.png (26.13 KiB) Viewed 1231 times
ReticleType("Vehicle");
ReticleType("Vehicle");
vehicle.png (26.13 KiB) Viewed 1231 times
small.png
ReticleType("Small");
small.png (14.15 KiB) Viewed 1231 times
ReticleType("Small");
ReticleType("Small");
small.png (14.15 KiB) Viewed 1231 times
large.png
ReticleType("Large");
large.png (181.51 KiB) Viewed 1231 times
ReticleType("Large");
ReticleType("Large");
large.png (181.51 KiB) Viewed 1231 times
I may not make the best maps, or be the best player, but I put a lot of time, effort, and care into my stuff. That counts for something, right? No.
Image
"Can we order a pizza?"
GameRanger ID: 913974
User avatar
Magnos
Half Track
Half Track
Posts: 61
Joined: Sun Dec 16, 2018 1:27 pm
Egypt

Re: Reticle Type in MapObj()??

Post by Magnos »

TommyCD1 wrote: Sun Nov 24, 2019 6:44 am That defines the HUD elements a unit uses when you mouse over it.
There are three different types:
  • Small
  • Large
  • Vehicle
The types 'Small' and 'Large' are assigned automatically by the game dependent on if the objects godfile uses a driver. (As in can the unit move around or does it zip to the map.)
The third type 'Vehicle' can be assigned manually instead of using the 'Small' type. It is the same as the small type, except it will always display two corners on the health bar when owned by someone else.
Thank you,
What is CommandCost too?
User avatar
TommyCD1
Moderator
Moderator
Posts: 1146
Joined: Tue Jun 04, 2013 8:55 am
Location: East Coast
Contact:
United States of America

Re: Reticle Type in MapObj()??

Post by TommyCD1 »

CommandCost is the amount of spaces a unit takes up for the unit limit.
The game's unit limit is hard-coded at 70. The command cost is how many spaces that unit takes up, for example right now each unit costs 1. So you can have 70 units total. CommandCost can be any positive integer, which will affect the unit limit accordingly.
  • CommandCost(0); - Unit will not count towards unit limit: You can build as many as you like.
  • CommandCost(1); - Unit will count once toward the unit limit: You can build 70 before being capped.
  • CommandCost(2); - Unit will count twice toward the unit limit: You can build 35 before being capped.
Keep in mind that the unit limit is global, so combinations of different command costs will be totaled to find the current number of units. For example: You could have 7 units with 10 command cost each, and will trigger 70 units. But you can also have 5 units with 10 command cost, 2 units with 5 command cost, and 7 units with 1 command cost, and will trigger only have 70 units.

Lasty, there's a glitch in the game's engine, where if you exceed the unit limit, either by building a unit that would put you OVER 70 units, or by building two units at the same time with multiple buildings, then the game will prevent you from building any units AT ALL. Even if they would not cost towards the limit, such as CommandCost(0);, or air strikes.

Of course, there are two ways to change the unit limit itself. The first is to use an objective within the mission itself. If you use this line
  • SetUnitLimit(70);
in the objective's Action() module, then you can modify the unit limit on a per team basis. The second way to do this is by using unitlimit.cfg . This can also be changed to affect all teams always, but will cause online desyncing. It can be applied as a base.x mod.

Code: Select all

///////////////////////////////////////////////////////////////////////////////
//
// Pandemic Studios
//
// Unit Construction Limits
//

Limit(70);
Setting the unit limit to 0 with either of these methods will NOT give you infinite units. You'll instead need to set it exceedingly high (such as 9999999999) in order to preclude ever hitting it.
I may not make the best maps, or be the best player, but I put a lot of time, effort, and care into my stuff. That counts for something, right? No.
Image
"Can we order a pizza?"
GameRanger ID: 913974
User avatar
Magnos
Half Track
Half Track
Posts: 61
Joined: Sun Dec 16, 2018 1:27 pm
Egypt

Re: Reticle Type in MapObj()??

Post by Magnos »

TommyCD1 wrote: Sun Nov 24, 2019 10:29 pm CommandCost is the amount of spaces a unit takes up for the unit limit.
The game's unit limit is hard-coded at 70. The command cost is how many spaces that unit takes up, for example right now each unit costs 1. So you can have 70 units total. CommandCost can be any positive integer, which will affect the unit limit accordingly.
  • CommandCost(0); - Unit will not count towards unit limit: You can build as many as you like.
  • CommandCost(1); - Unit will count once toward the unit limit: You can build 70 before being capped.
  • CommandCost(2); - Unit will count twice toward the unit limit: You can build 35 before being capped.
Keep in mind that the unit limit is global, so combinations of different command costs will be totaled to find the current number of units. For example: You could have 7 units with 10 command cost each, and will trigger 70 units. But you can also have 5 units with 10 command cost, 2 units with 5 command cost, and 7 units with 1 command cost, and will trigger only have 70 units.

Lasty, there's a glitch in the game's engine, where if you exceed the unit limit, either by building a unit that would put you OVER 70 units, or by building two units at the same time with multiple buildings, then the game will prevent you from building any units AT ALL. Even if they would not cost towards the limit, such as CommandCost(0);, or air strikes.

Of course, there are two ways to change the unit limit itself. The first is to use an objective within the mission itself. If you use this line
  • SetUnitLimit(70);
in the objective's Action() module, then you can modify the unit limit on a per team basis. The second way to do this is by using unitlimit.cfg . This can also be changed to affect all teams always, but will cause online desyncing. It can be applied as a base.x mod.

Code: Select all

///////////////////////////////////////////////////////////////////////////////
//
// Pandemic Studios
//
// Unit Construction Limits
//

Limit(70);
Setting the unit limit to 0 with either of these methods will NOT give you infinite units. You'll instead need to set it exceedingly high (such as 9999999999) in order to preclude ever hitting it.
Thank You very much.
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests