Search the Community
Showing results for tags 'rank'.
Found 5 results
-
Code Snippet for Interaction Rank Based Victory Check
Supernova187 posted a topic in Arma Reforger - Configs & Scripting
In my quest to recreate the Escort game mode from AA3, I've finally figured out to have a victory condition check rank. I've left in some of my incomplete efforts regarding getting rank name, but this works off the rank number(?) ("8" for CUSTOM1). I've left the print statements for debugging purposes commented out. This is based on the tutorial by UselessFodder and example code from Bohemia found here: https://community.bistudio.com/wiki/Arma_Reforger:Action_Context_Setup class MyScriptedUserAction : ScriptedUserAction { //------------------------------------------------------------------------------------------------ override void PerformAction(IEntity pOwnerEntity, IEntity pUserEntity) { SCR_ChimeraCharacter character = SCR_ChimeraCharacter.Cast(pUserEntity); Faction faction = character.GetFaction(); //string factionName = faction.GetFactionName(); //Print(factionName); string characterName = character.GetName(); //Print(characterName); ECharacterRank rank = SCR_CharacterRankComponent.GetCharacterRank(pUserEntity); string rankNumber = rank.ToString(); //string rankName = SCR_CharacterRank.GetRankName(pUserEntity); //string rankName = SCR_CharacterRankComponent.GetCharacterRankNameUpperCase(pUserEntity); //Print(rankNumber); if (faction) { if (rankNumber == "8") { VIPExtractVictory(faction); } } } void VIPExtractVictory(Faction faction) { SCR_BaseGameMode gameMode = SCR_BaseGameMode.Cast(GetGame().GetGameMode()); int factionIndex = GetGame().GetFactionManager().GetFactionIndex(faction); gameMode.EndGameMode(SCR_GameModeEndData.CreateSimple(SCR_GameModeEndData.ENDREASON_EDITOR_FACTION_VICTORY, -1, factionIndex)); } };- 3 replies
-
- 2
-
- enforce script
- rank
-
(and 1 more)
Tagged with:
-
I use a rating system that gives you rating or takes it away depending on who you kill. not sure where i got it from. Rating.sqf Added the zombie part with help form Haleks. Ravage mod. Added with one a couple i have made. A script that checks your rating and promotes or demotes you depending on your rating Rank.sqf Promoted.sqf Demoted.sqf Now the problem i have encounted and cant seem to fix is that the rank.sqf only fires one time. As in you will be promoted one rank or demoted one rank. So you can go form private to corporal but not any higher. Then you can go back from corporal to private. If you get demoted back to private you can still get promoted up to corporal again. The problem may lie in the fact that if you get promoted or demoted your rating goes back to 0. You can also start the game as a Sargent and get promoted once and demoted once. Not sure what is going on. The promote and demote scripts work fine one there own but the rank.sqf is what im having problems with. Any help would be awesome thank you
-
It would be great to have a system that automatically synchronizes the in-game unit's rank with the online rank in the Bohemia website.
-
Highest ranked member in group not leader
Maurdekye posted a topic in ARMA 3 - MISSION EDITING & SCRIPTING
I'm trying to place a custom group of units. I placed 5 units on the ground in the 3d editor (Missile Specialist (AT), Combat Life Saver, Autorifleman, Marksman, and an Officer). I linked them all together, but the group leader was the missile specialist instead of the officer. So I made sure all the units were at the rank of Private, and then set the rank of the officer to Seargent. But the missile specialist was still the group leader. No matter what I did I could not get any other unit to be the group leader. -
Scott F. Miller's Captain Rank? (Army,Navy or Air force)
God of Monkeys posted a topic in ARMA 3 - OFFICIAL MISSIONS
Hi, I very curious about Miller's Captain Rank. Because Captain in army, navy or air force have different rank, and when I translate this into Chinese, this will be a problem, because we call Captain in army or navy in Chinese is totally different word. Anybody know this? Thx