korbaach's Forum Posts

  • I will soon launch a C2 web site.. for native speakers of Aramaic,Klingon,Google Translate and Esperanto language..

    ..so if anyone is interested to help me..Welcome!

  • first..

    ------------------------------------------------------------------------------------------------------------------------------------------

    Thank you @Lordshiva1948 & LittleStain !

    That means a lot, coming from you guys...

    ------------------------------------------------------------------------------------------------------------------------------------------

    second...

    ...can load a map by its name without using the list object?

    Yes, you can!...

    Example, Player on collision with enemy => load map level28

    and if there are no map level28 ?!

    Ok. SkyLionGames ..

    I made an example based on screenshoot & capx you upload here

    with List object & Textbox. and Arrays...

    and later I see your previous topic :

    How do I save and load maps without arrays?

    [quote:b2fotsbi]I don't want to use arrays because arrays are confusing..

    so ..before I start to explain example I made..it would be good to tell me which part you do not understand..

  • [quote:ddxkis5r] ...but I can't load a file using a variable's name I guess

    How do I dynamically change the name of a XML file.

  • how can I ensure that, regardless of array size, the array is always populated as follows:

    with the "1"'s around the edges, and the "0"'s filling the rest ?

    If I understand correctly...

    Array For each XY element

    ....System:Compare two values

    Array.CurX=0|Array.CurY=0|Array.CurX=Array.Width-1|Array.CurY=Array.Height-1
    =1[/code:yaw5a9i8]
    Action.....Array set value at XY ...[b]X[/b](Array.CurX);[b]Y[/b](Array.CurY);[b]Value[/b](1)
  • I have a text file that is written like this.

    200;space,space,space,space...

    |space,space,space,space...

    120;space,space,space,space...

    |space,space,space,space...

    420;space,space,space,space...

    |space,space,space,space...

    try with trim

    trim(src)

    Return src with all whitespace (spaces, tabs etc.) removed from the beginning and end of the string.

    set Array to...trim(tokenat(etc...))

  • First .. I apologize to everyone who reference my old capx...

    I will not be able to access to my desktop (C2)..probably for another month.....25.01.2016...

    holiday trip ...

    Second..

    RenatoB you probably need server side solution...(PHP+MySQL) to share maps between players...

    that means...you need Ajax to $Post & $Get Data... from your own server...

    So... player need to be online to send or receive custom maps(Json Array Data)...and you need to build your server solution...

    On C2 tutorials.. if you search for PHP ,you'll find several tutorials about submit Hi-Score...I think that's a good start

    Another important ting...

    Always when you think... how to make HTML5 game (C2)..you think... how to make Web Site...

    and..any question "How to my game accesses certain user data?" actually is (roughly) question :

    "How to my web site accesses certain user data?"

    So ..when you make HTML5 game you are actually made Web Site..

    I have seen many questions on forum...like..Why my game can't access to some cusom folder and rip pictures to game..or why can't access to text file or camera...

    Would any of us really wanted to web site accesses our text,pictures or camera?!..

    You accidentally click on ads..you go on [LINK REMOVED - MOD] (please don't click on this link!)

    and web site colect all your personal data from comp...

    if I remember correctly..in example I use Browser ExecuteJs & FileReader() (The FileReader object lets web applications asynchronously read the contents of files (or raw data buffers) stored on the user's computer..)..

    and this is a relatively new permit for HTML5..it is still not allowed that website writes new data on your comp...

    I believe that you can bypass this limitation if you use NW.js ..but it means that you have to export game for comp(Win-Mac)

  • try css "outline"-"none" or "outline"-"0 px"

  • If there is no any setting inside construct, maybe something can change to the files like "c2runtime" or "jquery-2.1.1.min" maybe, i don't know..

    open index.html in text editor and change properties

  • I want to create an apple if the apple is randomly chosen, from a family where all 3 - orange banana and apple are inside the family.

    I think you can't..

    you cant write... create family member with instance variable "apple"

    but if I'm right this is going to do just that...

    random_Pick="apple"

    if c2 coose apple fom family..stop loop..everithig is ok..

    else keep trying(create&destroy) until you find apple..then stop

    Of course this does not make sense with "Random_Pick" variable,you dont need two times random pick..

    (variable and family (already picking random))..but if you have variable "Specific_Pick"..

    and set variable to specific fruit.. Specific_Pick="apple"..then you'll get apple

    have you even tried this?

    ..maybe I'm wrong

  • I mean something like this..

    so when you create sprite from family c2 take a random sprite..if is random sprite =Random pick..Stop

    else destroy and create new sprite..until you find Random pick

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • ..but could you explain with comment in each event that what is that doing..

    I'm sorry but I think that's a little bit excessive...

    BtnRestart on clicked-Restart Layout

    i think this is clear..also LocalStorage..

    On Start-check

    if missing -do someting

    if exists-get

    on get-do something

    only the array can be a little confusing..if you do not visualize how it actually looks

    so..in example you have 5 instance of same sprite..first instance always have IID=0;second=1

    just like frames in animation..array same case..first cell have index=0;second=1 etc

    so when you click on instance with IID=2..you save "clickCount"value in array on index 2

    then you save Array as Json...

  • Lets say I have: apple|orange|banana in my Fruit_family.

    The sprites are called apple, orange and banana respectively.

    Also I created a text variable: Random_Pick=""

    At the beginning there is a draw = pick either: apple, orange or banana.

    All is good, that all works I get the desired output when using output value to text.

    At this moment when I draw orange I get Random_Pick="orange"

    Now I would like for the Fruit_family to spawn the orange that I the system has randomly picked at the beginning at a certain location.

    I did as you suggested, added "Signature" Instance Variable to the Fruit_family, and named each of the objects as their sprites:

    apple=apple, orange=orange, banana=banana

    if you use while loop and "Random_Pick"?"Signature"...Destroy ?

    like in this capx WhileDestroy.capx

    just spawn families and check "Signature2...

  • something like 2NumbSum.capx ?