Is it bug or is it me?

This forum is currently in read-only mode.
  • I am trying to set a condition to create random number of objects of one type. For this i use GV that is being set at the start of layout. then, right under it i set that

    Value compare if ObjectX.Count is less then GV: create ObjectX

    sounds reasonable.

    But it doesnt work. Instead - when debuggin ive get and error saying:

    "ESpression 'Count': No 'ObjectX' object exists. returning zero.

    Well gee wiz, i know that theres no ObjectX and thats why i want the event to create them. Why its not working?

  • The object you're checking - is it a family or something else? Because using a family name and the .count expression, such as enemy.count doesn't work and always returns 0. You can work around this by using an event at the base level, then system>compare> is countmatching("enemy") less than x.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • thats why its so weird, i am not using fammilies at all O.o

    i just use "value compare" from system expresion. then in value one i click on the objectX from bottom microwindow and pick "number of objects"

    then as a value i just use GV.

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