UGX-Mods Login

or login with an authentication provider below
Sign In with Google
Sign In with Twitter
Sign In with Discord
Sign In with Steam
Sign In with Facebook
Sign In with Twitch

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - buttkicker845

This is a function inside of the utility for the ber2 map which is the "Eviction" mission
Code Snippet
Plaintext
// Will force an AI to use a turret
// Guy - Ai
// Turret - turret to use
// ender - what level notification will stop this thread
//This should be called using thread*
guy_stay_on_turret( guy, turret, ender )
{
if( IsDefined( ender ) )
{
level endon( ender );
}
turret endon( "death" );
guy endon( "death" );

level thread maps\_mgturret::mg42_setdifficulty( turret, getdifficulty() );
turret setmode( "auto_ai" );
turret SetTurretIgnoreGoals( true );

if( !IsDefined( guy GetTurret() ) )
{
guy UseTurret( turret );
}

wait( 0.5 );
}

If you want the guy to stop using the turret and move again you will need to use some notify to end the thread
6 years ago
Any call to a function will require a parameter () included in it, that is the easiest way to tell if something is a function or if its some kind of variable/data manipulation.

Function call:
Code Snippet
Plaintext
nodeOccupied = ai IsNodeOccupied(node); //determines if a pathnode is occupied by an AI and stores the result in nodeOccupied
variable manipulation:
Code Snippet
Plaintext
ai.ignoreSuppression = true; //makes the AI suppression from weapons

As for the definition of these functions specifically. I dont remember if both are engine functions but i do know that Hide() is, I have included a small description of each function for you
Code Snippet
Plaintext
trigger UseTriggerRequireLookAt();//makes it so the player must look directly at the trigger to use it
Code Snippet
Plaintext
model Hide();//makes any world entity invisible to the player, don't know if it removes collision of the entity
The best place to find information on a lot of the engine functions and some of the standard .gsc utility functions is to look at the script reference here: https://www.ugx-mods.com/script/#

Most of the utility functions found in the _utility.gsc and _zombiemode_utility.gsc has documentation on each of the functions and how to use them

I hope this helps!
6 years ago
to add to StupidEdits statement, DidUknowiPwn listed all of the available stat slots that are free to use. This can be found here: https://ugx-mods.com/forum/index.php/topic,11489.msg127382.html#msg127382
6 years ago
Looks cool, must have been a ton of work! congrats on the release!

Thanks man! Like i said it took about 2 years to development plus early this summer I scrapped about 75% of the code and started over but I'm sure it still didn't require as much work as the realism mod that you just released!
6 years ago
GG for this man *w*
Thank you, it has taken a lot of work to complete.
Well, this came out of nowhere, and it's incredible! Reminds me of spec ops, except a lot more customizable. Thanks for this!
I am glad you enjoyed it, it took over 2 years to complete. I've never really played the spec ops gamemode, but im glad that it reminds you of it
6 years ago
    Brothers in Arms MOD

    Abstract: Normandy, France 1944.
    The Allies have landed on the beaches in Normandy and are pushing their way into Nazi Occupied France. There is a long way to go before the Allies reach the heart of Germany. There will be multiple German Artillery Batteries and Supply Trucks that will need to be eliminated and German Intelligence that will need to be collected. Will you help the Allied Forces liberate Nazi Occupied France or help the Germans secure their foothold against the invading forces?

    Background: The Brothers in Arms series is a FPS Strategy game where you take the command of a squad-leader in WW2, released by Ubisoft in 2005. This is one of my favorite game series of all time. This is a MOD adaption of the squad-based action multiplayer scenarios of the first 2 games in the series.

    Features:
    • Command your squad in the heat of battle
    • Fight against AI in Solo or against friends in Co-op
    • Fight for both Allies and Axis
    • Multiple objective scenarios
                   -Destroy/Protect the Supply Truck
                   -Destroy/Protect the Anti-Aircraft Guns
                   -Secure/Escape with the Documents
    • Multiple levels to fight
                   -Carentan, France
                   -Burgundy, France

    Trailer:

    Gameplay:
    Images:
    Spoiler: click to open...









    Credits:
    Ubisoft- Original Game Development
    Activision - Development of CoD WaW and supporting MOD Tools
    asus891110 - Original Level Design
    BluntStuffy - Menu response tutorial
    DidUknowiPwn - Spawn weapon via script tutorial
    long cut loser - multiplayer testing
    Please let me know if you feel forgotten on this list!

    Controls:
    Please go into the Control settings and set the key bindings for "Command Squad" and "Squad Fall In" under the Interact menu!

    Use these keys to command your squad
    Press "Command Squad" to bring up the command ring and [Action] to confirm the move location
    Press "Squad Fall In" to have your squad fall you directly



    Update 1.1:
    - Fix for Player to Player damage, each time a Player damaged another Player no longer is counted as a kill
    - Removed Friendly Player to Player damage, Friendly Players can no longer damage each other

    Known Issues:
    Menu buttons don't flash after level restart

    Older Versions:
    Spoiler: click to open...
    Update 1.0:
    [/list][/list]
    6 years ago
    I've yet to see any of your code other than a single function line so I can't help you understand what is being done incorrectly if I don't know what you're doing other than a single line of code.

    Please post snippets of your actual code and then I would be happy to help you in the right direction with your issues of AI navigation.  :D
    6 years ago
    I'm pretty sure you've asked similar questions about AI navigation?  ???

    Anyways I've never used
    Code Snippet
    Plaintext
    <AI>  UseCoverNode( <path node> );

    I've only used
    Code Snippet
    Plaintext
    <AI>  SetGoalNode( <path node> );

    the different Cover Node classes are children of the Path Node class so they can be passed into the function properly and the AI will automatically play the animations for the cover
    Hope this helps :)
    6 years ago
    you can move an FX, but what you will want to do is use the function named
    Code Snippet
    Plaintext
    fx = playfxontag(id, ent, tag);
    where 'id' is the FX id, ent is the script_model that you want to play the FX on, and tag is the model tag you where you want the FX attached.
    example:
    Code Snippet
    Plaintext
    fx = PlayFxOnTag(level._effect["bouledefeu"], level.model, "tag_origin");
    PS: if you ran it in developer mode you should have gotten an error saying "Type String is not an entity and cannot call EnableLinkTo"
    6 years ago
    it does not work on which part? it doesnt modify the speed of the door or doesnt play the custom sound?

    if its the sound i would say that the sound isn't being loaded into the .ff of your map/mod correctly
    6 years ago
    The script already has code for adding both custom sounds as well as a custom rotate speed.

    If you add these to KVPs on the door itself and not the trigger it will change these behaviors
    Code Snippet
    Plaintext
    Key: script_sound Value: custom_sound
    and
    Code Snippet
    Plaintext
    Key: script_transition_time Value: 2 //will take 2 seconds to rotate
    6 years ago
    It would be hard to just tell you where to place these functions since all used for deciding where you want AI to navigate to. The SetGoalNode(node) is for sending the AI to a location after you've decided which node you want to send them to.

    If you want to send an AI to an objective you do so by
    Code Snippet
    Plaintext
    //Note: this simply moves an AI to the objective position, doesn't account for the fact that there may already be someone there
    nodes = level GetAllNodes();
    moveToNode = getClosest(objective.origin, nodes);
    ai SetGoalNode(moveToNode);

    Need to use to ensure that the AI is able to move to the node, if the node is occupied the AI will not move
    Code Snippet
    Plaintext
    nodes = level GetAllNodes();
    moveToNode = getClosest(objective.origin, nodes);
    //this will move the AI to node only if it isnt being occupied by another friendly AI
    If(!IsNodeOccupied(moveToNode))
    {
         ai SetGoalNode(moveToNode);
    }

    I hope that helps you under stand how to use these functions together to allow your AI to move  :)
    7 years ago
    no problem is is some short descriptions of the functions
    Code Snippet
    Plaintext
    ai SetGoalNode(node);//makes the ai move to a specific pathnode in the world, node is a pathnode or covernode

    Code Snippet
    Plaintext
    if(IsNodeOccupied(node)) //checks to see if a friendly ai is already using this node, returns boolean value

    to collect all path, cover, and ai negotiation nodes in the world use
    Code Snippet
    Plaintext
    nodes = level GetAllNodes();
    7 years ago
    friendly Ai in WAW act wierd

    For starters they don't like to move with the command of
    Code Snippet
    Plaintext
    SetGoalPos(mg.pos)
    instead try to use
    Code Snippet
    Plaintext
    SetGoalNode(node)
    . Also unlike enemy AI friendlies can't be sent to the same node or goal position like you can with enemies. If you send friendlies to the same goal node only one of them will move and the rest will stay, so be sure to make use of
    Code Snippet
    Plaintext
    IsNodeOccupied(node)
    .

    PS: for enemy AI the function IsNodeOccupied() is always false
    7 years ago
    the pap perk would be something like this
    Code Snippet
    Plaintext
    pap_powerup()
    {
    //ensure the player is valid
    if(!is_player_valid(self))
    {
    return;
    }
    currentWeapon = self GetCurrentWeapon();
    //ensure current weapon exists, its not a grenade and that its not already upgraded
    if(!isDefined(currentWeapon) || getWeaponType(currentWeapon) == "grenade" || isSubStr(currentWeapon, "upgraded"))
    {
    return;
    }
    //make the weapon upgraded
    upgradeWeapon +=  "_upgraded";
    //take the current weapon and give the upgraded one
    self takeWeapon(currentWeapon);
    self giveWeapon(upgradeWeapon);
    self switchTo(upgradeWeapon);
    }
    7 years ago
    Loading ...