Magistross's Recent Forum Activity

  • There's a way to do it using a family and a function, however, you will have one sub-event for each enemy under the function. Here's a quick example :

    https://dl.dropboxusercontent.com/u/700 ... bject.capx

    However, Rex's Nickname behavior is a far better solution, if having 3rd party plugin is alright with you!

  • LuciusCD

    Yes it's possible, even though the fork command is originally intended only for a two branch. You'd have to use multiple sequences with only a fork command to simulate a triple branched fork. Here, you can load this dialogue JSON and see how I'd do it.

    fremachuca

    Unfortunately, the utility is the only "official" way to organize and edit your dialogues. However, it would be quite possible to create a Google Apps Script to generate a DialogueDictionary JSON from a spreadsheet given that all the data follow a specific template.

    A choice "command" is definitely something I want to add. However, I'm still struggling on how to organize things so that it becomes easily customizable... Stay tuned for this functionality !

  • LuciusCD

    Certainly, the window is a 9-patch object, you can use any image you want. The size of the window and a lot of other options can be changed by simply modifying a few variables. The cursor object is a simple sprite, that can be changed to whatever you want, animated or not. The system use exclusively spritefonts, but you can use anyone you like, you just have to make sure you adjust some of the variables like the line-height so the system knows when to "overflow".

    You can basically "theme" this dialogue system in any way you want, and still retain its full functionnality by adjusting a few variables in edit time.

    Please let me know if you have any further question!

  • Oh, forgot about that part. The JSON file must be loaded via the "Load" action of the "DialogueDictionary". Best if you add the JSON file as a project file too first. There's probably a tutorial on how to load an external file somewhere but basically all you have to do is use the AJAX object, request a project file, and "Load" the AJAX.LastData inside the Dictionary with a "on request complete" event.

  • It would be awesome if you could make a simple "get started" tutorial on how to implement this into another project.

    It's certainly the hardest part of this template, getting it to work inside an existing capx! However, when you know what to copy over, it's not that complicated, here's the breakdown of what you should do :

    1. Copy these objects to your project (an event-less layout works wonder, like the "Dummy" layout) : ContinueIndicator, PortraitSprite, SpriteFont, WindowFrame

    (edit: Version 1.02 now needs additional objects : UpArrow, DownArrow, ChoiceSelector)

    2. Create these objects and name them like so :

    1 Array Object named "DialogueData"

    1 Dictionnary Object named "DialogueDictionary"

    1 Dictionnary Object named "DialogueCommands"

    1 Dictionnary Object named "GameVariables" (this is where you game should store its variables, so that dialogues can fetch them)

    1 Function Object named "Function" (default)

    1 Browser Object named "Browser" (default)

    1 Audio Object named "Audio" (default)

    3. Create a new event sheet, and copy over all the content from the "DialogueEvents" sheet from the template. If all objects were correctly copied / created, it should give no error message. (per haddy22 's remark, variables should be copied over before other events, so doing it in chunks might be better)

    4. Include this new event sheet inside whatever layout where you want to use the system.

    5. Be sure to have a "HUD" layer in all your layouts where you need dialogues. (You can also define your own layer by changing the "DIALOGUE_LAYER" constant)

    6. You can then initiate a dialogue with the "Dialogue_StartDialogue" function. It will start a dialogue with the data currently in the "DialogueData" array, or you can also provide a "key" parameter, it will then load the dialogue from the "DialogueDictionary" and start it. An AJAX call to retrieve either an array or a dictionnary JSON will most likely be needed.

    Please let me know if you need further help !

  • You might want to look at the Sine behavior.

    Here's how I'd do it. Cheap and easy !

  • You can return a tokenized string or a JSON object that C2 can interpret.

  • You can use "IndexOf" expression to retrieve the index of an element. It works only on the X axis though.

  • I suspect you used the System's "Create object" action to spawn your projectiles. It fires only once, no matter how many objects currently in the SOL. You can either add a "For each enemy object" condition or replace the action by a "Spawn object" under your enemy sprite object.

  • All instances of a given tilemap object share a single bitmap. No matter how hard you try, it is simply not possible. Sorry...

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You are missing a "For each Blok" under your line 3 condition. If more than a block is destroyed in a tick, your array will start to desync with the actual grid.

  • You could use shared global variables using a dedicated event sheet for that, and include it in both layout 1 and 5 event sheet. Or use a global Dictionnary Object (they come set to global by default).

Magistross's avatar

Magistross

Member since 4 Jul, 2011

Twitter
Magistross has 14 followers

Trophy Case

  • 13-Year Club
  • Entrepreneur Sold something in the asset store
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Regular Visitor Visited Construct.net 7 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

20/44
How to earn trophies