Latest topics
» Omg this server with the website is still alive :oby Razor Tue Nov 19, 2024 10:17 pm
» [Solved] Help & Support
by VK.Angel.OfDeath Thu Oct 24, 2024 7:02 pm
» [Solved] reset password
by VK.Angel.OfDeath Thu Oct 24, 2024 6:58 pm
» [Accepted] Report - Abanoub^
by VK.Angel.OfDeath Thu Oct 24, 2024 6:42 pm
» [Accepted] Unban appeal - hasan
by D4rKR420R Fri Oct 18, 2024 10:06 pm
» [Solved] Report - BelondiOscar
by SJIsNotHere Fri Oct 11, 2024 1:21 pm
» [Solved] Geogeo - Stats Transfer
by SJIsNotHere Tue Oct 01, 2024 5:50 pm
» [Solved] Kindly Re-solve it
by SJIsNotHere Wed Sep 25, 2024 9:55 am
» [Solved] Geogeo - Stats Transfer
by SJIsNotHere Wed Sep 25, 2024 8:10 am
» Matija_Todorovic returns after 3 years of absence
by UmaR Sun Sep 01, 2024 5:55 am
» [Solved] Signature^-Stats transfer
by UmaR Wed Aug 21, 2024 2:38 pm
» [Denied] Admin Application - MK14
by UmaR Fri Aug 16, 2024 8:44 pm
» [Solved] Reset my password pls
by VK.Angel.OfDeath Wed Aug 14, 2024 6:44 am
» Old member back from the dead
by Neptune Mon Aug 12, 2024 9:39 pm
» Vice War X Gameplay | BadDiamondArtz VCMP
by UmaR Thu Jul 18, 2024 10:00 am
» [Solved] RESET PASSWORD
by UmaR Fri Jul 12, 2024 3:29 pm
» [Solved]Transfer Application - Hazard
by SJIsNotHere Wed Jul 03, 2024 10:56 am
» DARKRAZOR RESPONDE MI MENSAJE!!!
by Veterano789 Wed Jul 03, 2024 1:59 am
» Vice War X: The Starfish Showdown
by =FF=B00M_B00M^ Thu Jun 27, 2024 6:17 pm
» Fatal Force - F2
by Mr.Moon Wed Jun 26, 2024 7:18 am
» Stat Transfer Application - SuFyastiC
by D4rKR420R Tue Jun 04, 2024 10:07 pm
» [Accepted] Unban Appeal
by VK.Angel.OfDeath Sun Mar 31, 2024 8:29 am
» [Solved] Password Reset
by VK.Angel.OfDeath Sat Mar 23, 2024 9:32 pm
» Ramadan Mubarak in Advance
by Shafin Sat Mar 23, 2024 1:52 pm
» Illegal Immigration | Old Memories | 2017
by ilemius Fri Feb 09, 2024 5:25 pm
» VKs and VCMP Previews
by SJIsNotHere Sat Jan 20, 2024 1:51 pm
» The Resurgence 4th Year of Anniversary!
by Ninja Tue Jan 16, 2024 10:30 am
» [Solved]Stats Transfer application - Shado[W]^
by SJIsNotHere Mon Nov 27, 2023 5:06 pm
» Hi to all my good friends
by VK.Angel.OfDeath Sat Nov 18, 2023 9:04 am
» [Closed] Admin Application - F2.Ninja
by VK.Angel.OfDeath Sat Nov 18, 2023 8:49 am
Top posters
ЧК. (8555) | ||||
VK.Angel.OfDeath (6465) | ||||
=SdS=KrlozZ... (6433) | ||||
D4rKR420R (5473) | ||||
=KF=Thunder^ (5405) | ||||
Pavonis (5197) | ||||
SJIsNotHere (4432) | ||||
Emma (4261) | ||||
Vipe[R] (3756) | ||||
47. (3705) |
Statistics
We have 1978 registered usersThe newest registered user is kodaklyve
Our users have posted a total of 217905 messages in 16831 subjects
Most Viewed Topics
[HARD] Make Team Scores with different max scores for winning
3 posters
VKs Official Server :: Server Information :: Server information :: Official Tutorials :: Property Variables
Page 1 of 1
[HARD] Make Team Scores with different max scores for winning
Information
So in games like CTF. There are two teams: Blue and Red. Each team got a score and when the team reaches 3 scores, 5 scores, 9 scores or whatever it wins.
Can we do that in the variable system? Of course we can. I will tell you.
Team Red
We need to first set to score to zero when starting and then have one variable for increasing the score.
Setting it to 0 to start
/addvariablepickup var_red 0 => Index 0
Increasing the score by 1 when the team gets a score:
/addchangevariablepickup var_red 1 => Index 1
Team Blue
Repeating the same steps for blue:
Setting it to 0 to start
/addvariablepickup var_blue 0 => Index 2
Increasing the score by 1 when the team gets a score:
/addchangevariablepickup var_red 1 => Index 3
Winning
In this example we will display a message if team blue or team red wins like this:
/addmsgallpickup Team Read wins! => Index 4
/addmsgallpickup Team Blue wins! => Index 5
Now we need to put conditions on index 4 and 5 so they are only displayed when someone wins.
When does a team win? When it's score reaches the max score.
I will give two examples. Read the one that applies to you.
Example 1: Where you want the team blue or red to win if they get 3 scores!
Setting the condition for "team red winning" message:
/changepickupcondition 4 var_red >= 3
Setting the condition for "team blue winning" message:
/changepickupcondition 5 var_blue >= 3
Now when you enter Index 4, the message: "Team red wins" will be displayed if team red has 3 scores.
or if you enter index 5, the message: "Team blue wins" will be displayed if team blue has 3 scores.
The rest is up to you what you want to do with your minigame.
Example 2: Where you want to be able to set the max score to 3, 7 or 9 at the start of the game to determine in which score the team blue or red to wins the game.
Create a variable to determine the max score instead of using the value 3 like in example 1.
/addvariablepickup var_max_score 3 => Index 6
/addvariablepickup var_max_score 5 => Index 7
/addvariablepickup var_max_score 9 => Index 8
Now to select the max score of the minigame to determine when someone wins. Enter one of these pickups at the start
Repeat example 1 but replace all "3" in the conditions with var_max_score. Press the spoiler below to see the result:
So in games like CTF. There are two teams: Blue and Red. Each team got a score and when the team reaches 3 scores, 5 scores, 9 scores or whatever it wins.
Can we do that in the variable system? Of course we can. I will tell you.
Team Red
We need to first set to score to zero when starting and then have one variable for increasing the score.
Setting it to 0 to start
/addvariablepickup var_red 0 => Index 0
Increasing the score by 1 when the team gets a score:
/addchangevariablepickup var_red 1 => Index 1
Team Blue
Repeating the same steps for blue:
Setting it to 0 to start
/addvariablepickup var_blue 0 => Index 2
Increasing the score by 1 when the team gets a score:
/addchangevariablepickup var_red 1 => Index 3
Winning
In this example we will display a message if team blue or team red wins like this:
/addmsgallpickup Team Read wins! => Index 4
/addmsgallpickup Team Blue wins! => Index 5
Now we need to put conditions on index 4 and 5 so they are only displayed when someone wins.
When does a team win? When it's score reaches the max score.
I will give two examples. Read the one that applies to you.
Example 1: Where you want the team blue or red to win if they get 3 scores!
Setting the condition for "team red winning" message:
/changepickupcondition 4 var_red >= 3
Setting the condition for "team blue winning" message:
/changepickupcondition 5 var_blue >= 3
Now when you enter Index 4, the message: "Team red wins" will be displayed if team red has 3 scores.
or if you enter index 5, the message: "Team blue wins" will be displayed if team blue has 3 scores.
The rest is up to you what you want to do with your minigame.
Example 2: Where you want to be able to set the max score to 3, 7 or 9 at the start of the game to determine in which score the team blue or red to wins the game.
Create a variable to determine the max score instead of using the value 3 like in example 1.
/addvariablepickup var_max_score 3 => Index 6
/addvariablepickup var_max_score 5 => Index 7
/addvariablepickup var_max_score 9 => Index 8
Now to select the max score of the minigame to determine when someone wins. Enter one of these pickups at the start
Repeat example 1 but replace all "3" in the conditions with var_max_score. Press the spoiler below to see the result:
- Repeated from example 1:
- Setting the condition for "team red winning" message:
/changepickupcondition 4 var_red >= var_max_score
Setting the condition for "team blue winning" message:
/changepickupcondition 5 var_blue >= var_max_score
Now when you enter Index 4, the message: "Team red wins" will be displayed if team red has var_max_score scores.
or if you enter index 5, the message: "Team blue wins" will be displayed if team blue has var_max_score scores.
The rest is up to you what you want to do with your minigame.
VK.Angel.OfDeath- Server Owner & Forum Admin
- Chuck NorrisedYou been norrised.
- Posts : 6465
Points : 9322
Reputation : 127
Join date : 2012-10-28
Age : 30
Location : Sweden
Re: [HARD] Make Team Scores with different max scores for winning
Awesome job man, you nailed it totally like scripting
S.- Legendary Member
- Gender :
Posts : 1184
Points : 2065
Reputation : 5
Join date : 2018-12-11
Age : 18
Location : Somewhere in clouds
Re: [HARD] Make Team Scores with different max scores for winning
_ wrote:Awesome job man, you nailed it totally like scripting
This part only covers player variables of the person entering the pickup. The next system coming in a few weeks (I already tested it) will add vehicle, object, pickup, npc support and support for checking other players variables, as well as some more useful functions for scripting.
After that you can cover most of it. We still don't have anything for changing default variables (player, vehicle, npc, etc.. variables) other than pickups, but there are over 100+ pickups so I think my property system covers everything by next patch.
It's exciting though because we are getting closer and closer to replacing scripting if that ever will happen we'll see I doubt it will replace 100 % of the work but hopefully 90-99 % in the future.
VK.Angel.OfDeath- Server Owner & Forum Admin
- Chuck NorrisedYou been norrised.
- Posts : 6465
Points : 9322
Reputation : 127
Join date : 2012-10-28
Age : 30
Location : Sweden
Re: [HARD] Make Team Scores with different max scores for winning
_ wrote:Awesome job man, you nailed it totally like scripting
MeLoDy^- Legendary Member
- Gender :
Posts : 1150
Points : 1647
Reputation : 5
Join date : 2018-12-10
Age : 20
Location : East Side.
Re: [HARD] Make Team Scores with different max scores for winning
I'll wait for the next release, keep up the great job. Although anything in VKs is implemented from DM to customizing your own world with anything you want. The lag is decreasing too and hope of it to decrease more in future, keep it up!VK.Angel.OfDeath wrote:_ wrote:Awesome job man, you nailed it totally like scripting
This part only covers player variables of the person entering the pickup. The next system coming in a few weeks (I already tested it) will add vehicle, object, pickup, npc support and support for checking other players variables, as well as some more useful functions for scripting.
After that you can cover most of it. We still don't have anything for changing default variables (player, vehicle, npc, etc.. variables) other than pickups, but there are over 100+ pickups so I think my property system covers everything by next patch.
It's exciting though because we are getting closer and closer to replacing scripting if that ever will happen we'll see I doubt it will replace 100 % of the work but hopefully 90-99 % in the future.
S.- Legendary Member
- Gender :
Posts : 1184
Points : 2065
Reputation : 5
Join date : 2018-12-11
Age : 18
Location : Somewhere in clouds
Re: [HARD] Make Team Scores with different max scores for winning
_ wrote:I'll wait for the next release, keep up the great job. Although anything in VKs is implemented from DM to customizing your own world with anything you want. The lag is decreasing too and hope of it to decrease more in future, keep it up!VK.Angel.OfDeath wrote:_ wrote:Awesome job man, you nailed it totally like scripting
This part only covers player variables of the person entering the pickup. The next system coming in a few weeks (I already tested it) will add vehicle, object, pickup, npc support and support for checking other players variables, as well as some more useful functions for scripting.
After that you can cover most of it. We still don't have anything for changing default variables (player, vehicle, npc, etc.. variables) other than pickups, but there are over 100+ pickups so I think my property system covers everything by next patch.
It's exciting though because we are getting closer and closer to replacing scripting if that ever will happen we'll see I doubt it will replace 100 % of the work but hopefully 90-99 % in the future.
Like I mentioned a few patches ago I optimized the database. Killing another player could before cause about 20-100 in temp ping increase. I optimized the script so the value is between 0.5-2 ping per kill which is hardly nothing.
Still more to be done. It's not as optimized as other servers of course since it's so big.
VK.Angel.OfDeath- Server Owner & Forum Admin
- Chuck NorrisedYou been norrised.
- Posts : 6465
Points : 9322
Reputation : 127
Join date : 2012-10-28
Age : 30
Location : Sweden
S. likes this post
Similar topics
» [Closed] Make legal using Minigun in BOD & make ammunation levels easier
» [Denied] =M4z=Pro. Team Grief / Team killing
» Another #Winning Moment!
» VKs Official Server Admins and Moderators
» MAKE VKS BEST AGAIN!!!!!!!!!
» [Denied] =M4z=Pro. Team Grief / Team killing
» Another #Winning Moment!
» VKs Official Server Admins and Moderators
» MAKE VKS BEST AGAIN!!!!!!!!!
VKs Official Server :: Server Information :: Server information :: Official Tutorials :: Property Variables
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum