August 23, 2019, 07:47:24 AM

Author Topic: [Addon] Changerace for Bots  (Read 1166 times)

Offline Manifest

  • Race & effect creator
  • Moderator
  • Level 7 Expert
  • *****
  • Posts: 1063
  • Country: dk
  • Content creator for the new WCS version by Kami.
[Addon] Changerace for Bots
« on: January 18, 2018, 02:45:00 PM »
This type of addon have been made and released multiple times on the forum, I do not know the original author of this addon, but here is the version for the new WCS with my own take on it.

About the addon.
In short, this addon basically allow bots to change their races just like players can. Whenever a bot dies it has 10% chance to change their race to one of the twelve default races released in the new WCS version.

It should be rather easy for people to add additional races if they wish to do so, they can go and edit the es_addon_botrace_randomizer.txt I have tried to make the system as transparent as possible, so it should be easy to understand how it works.


The addon itself will be added to this post later, I will bump it when it happens, we will be implementing some necessities for this to work in to the WCS version, that is why the addon won't be added right away.

(◠‿◠)
« Last Edit: January 20, 2018, 03:22:44 AM by Manifest »
"BRAVORA: Bruh it is fucking operation crystal night when you are approving races."


Offline Manifest

  • Race & effect creator
  • Moderator
  • Level 7 Expert
  • *****
  • Posts: 1063
  • Country: dk
  • Content creator for the new WCS version by Kami.
Re: [Addon] Changerace for Bots
« Reply #1 on: January 20, 2018, 03:25:59 AM »
Just as promised, now that we have the wcs_changerace command in place, the actual addon has now been added, and are available for download below.

Kami and I made a change to this addon, now it will no longer just change the bot's race between the standard ones, but it will change the bot's race between all the races that the bot has currently unlocked. A vast improvement to the actual idea, the new and updated file have been added in the original post above. ;)

Enjoy some more lively gameplay from your bots!
"BRAVORA: Bruh it is fucking operation crystal night when you are approving races."


Offline WCS - Wookie

  • Level 6 Experienced
  • *****
  • Posts: 133
  • Country: nz
  • Qualified Teacher, working in IT and loving WCS.
Re: [Addon] Changerace for Bots
« Reply #2 on: January 20, 2018, 06:15:18 AM »
Dude, that sounds awesome!

I really need to get my ass into gear and finish setting up my server for the new version so I can test all these awesome new addons and reworks. <3 <3 <3
If you like WCS and are from AUS/NZ drop by our server to take a look.


Offline Osker Lee

  • Level 0 Beginner
  • Posts: 15
  • <3 WCS :)
Re: [Addon] Changerace for Bots
« Reply #3 on: January 09, 2019, 11:00:05 AM »
In my cs source server,the bots still can't change their races,they only choose the Undead Scourge,not random races.Shall i need to edit the addon_botrace_randomizer.txt?

Sorry for my poor English.
« Last Edit: January 09, 2019, 11:17:38 AM by Osker Lee »

Offline WCS - Wookie

  • Level 6 Experienced
  • *****
  • Posts: 133
  • Country: nz
  • Qualified Teacher, working in IT and loving WCS.
Re: [Addon] Changerace for Bots
« Reply #4 on: January 10, 2019, 04:40:23 AM »
Hi Osker,

I am not currently running any servers to test this but if you follow the instructions included in the addon download then you should be able to get it to work.

Please make sure that you read and follow the instructions correctly.
If you like WCS and are from AUS/NZ drop by our server to take a look.


Offline Osker Lee

  • Level 0 Beginner
  • Posts: 15
  • <3 WCS :)
Re: [Addon] Changerace for Bots
« Reply #5 on: January 21, 2019, 10:10:07 AM »
[console] es_load: Could not open script for wcs/tools/trixie/addon_botrace_randomizer

Offline Manifest

  • Race & effect creator
  • Moderator
  • Level 7 Expert
  • *****
  • Posts: 1063
  • Country: dk
  • Content creator for the new WCS version by Kami.
Re: [Addon] Changerace for Bots
« Reply #6 on: January 24, 2019, 11:44:14 AM »
Hi Oskar, sorry for the late reply.

First and foremost, this addon is tested, and it works for the version of Kami's Warcraft Source which it was designed for, I haven't tested it on Tha Pwned's version, but in order for the addon to work it requires your server to be able to use th two following commands:

wcs_getrandomrace
wcs_changerace

If these commands aren't in that version, then this addon won't work.

Judging by your latest reply to this topic however;
Quote
[console] es_load: Could not open script for wcs/tools/trixie/addon_botrace_randomizer

it would appear as if you're trying to load the script, but the script is actually not on the server, and if it is on the server, then it isn't located in the right directory.

Please check and make sure that it is in the right directory and then try loading it once more. Please let me know how your results from doing this.
"BRAVORA: Bruh it is fucking operation crystal night when you are approving races."


Offline Osker Lee

  • Level 0 Beginner
  • Posts: 15
  • <3 WCS :)
Re: [Addon] Changerace for Bots
« Reply #7 on: January 24, 2019, 07:20:21 PM »
In the es_addon_botrace_randomizer.txt, I see this code:
es wcs_changerace event_var(userid) server_var(wcs_botrace)

So, what is the meaning of "wcs_botrace"? Except the es_addon_botrace_randomizer.txt, I can't find it anywhere. Is it a new script or a new file?

Offline Manifest

  • Race & effect creator
  • Moderator
  • Level 7 Expert
  • *****
  • Posts: 1063
  • Country: dk
  • Content creator for the new WCS version by Kami.
Re: [Addon] Changerace for Bots
« Reply #8 on: January 25, 2019, 12:19:26 AM »
Okay, so, in the es_addon_botrace_randomizer.txt there's used a variable, that variable is wcs_botrace.
It's being used to store data within, it's storing all the races that are available for the bot to play as, and is then used in the line es wcs_changerace event_var(userid) server_var(wcs_botrace), that sets the race of the bot to one of the races available.

The wcs_botrace on it's own has no actual functionality it could've been called anything. What is important are the commands:

es wcs_getrandomrace event_var(userid) <variable>
es wcs_changerace event_var(userid) <variable>
"BRAVORA: Bruh it is fucking operation crystal night when you are approving races."