How do I call an object out of values?

0 favourites
  • 2 posts
From the Asset Store
Voice call plugin based on webrtc protocol for construct 3
  • In my game there are 2 teams (Dark and Light) and 2 classes (Assault and Support). I made 4 characters, each of which are related to those parameters (Dark_Assault_Soldier, Dark_Support_Solider, Light_Assault_Soldier, Light_Support_Soldier). In the loadout menu you can choose your team and your class,

    first you have to click either on the Light team or the Dark team, defining the "Team" value either as "Light_" or "Dark_", then same thing for the class ("Assault_" and "Support_").

    Is it possible, instead of directly selecting an object in the event menu, to make select a

    Team + Class + "Soldier" object?

    For example, I wonder if I can I make this:

    Every Tick => set Gun position to Team+Class+"Soldier" object

    Instead of making

    If Team="Light"

    ___If class="Assault" => Set gun position to Light_Assault_Soldier

    ___If class="Support"=> Set gun position to Light_Support_Soldier

    and etc... (it risks to be harder since I also plan to make the player choose between 4 guns and have a multiplayer mode...)

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I would put the characters in a family and give the family instance variables to identify the team and type and any other options.

    you can also define image points for each character with the same names so you always know right where things go.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)