lucid's Recent Forum Activity

  • Haven't tried your custom controls thing yet, Lucid.

    The idea is just that we should be able to easily control characters in cutscenes - if I just use X Velocity, the player moves, but the animations will be off, cause the velocity and the animation loop doesn't sync properly - or I'll have to precisely time it, which breaks in cases where a cutscene starts and the player could stand anywhere on the screen, but now has to go to X.

    That's the whole issue. It'd have to be like a script, remote controlling the players movement.

    If Cutscene 01 is '1', simulate player move to X.

    Which means that the player would move to X and the exact settings that I set-up in the platform behavior would still apply. Doing it over X Velocity won't ever work in those cases.

    I think you misunderstand me

    with the custom controls (or the built in mouse/keyboard, if they fixed that feature)

    you can use Set Control State to simulate a control press

    using setcontrolstate will make the character behave exactly as they do when you use the keyboard or a controller

    it's doing the same exact thing, you're basically using events as the controller instead of mouse keyboard or 360 pad

    so it does exactly what you're asking for, it simulates controller presses

    so if you wanted it to move like you're pressing a little bit to the right, you can say

    Set Control State ("Move Right", 0.3)

    or if you want it to be like you just pressed the jump button

    you can say Set Control State ("Jump",1)

    of course you have to set up extra events to know when a character gets somewhere to stop setting the control state and stop running

    btw, if the mousekeyboard one isn't working

    you can use the one in my plugin, without setting up all the custom control stuff, you could just use it for the SetControlState action to do that one thing, without worrying about setting up the control system in any other way

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • lord, sorry, I uploaded the wrong thing

    that supersprite was something else

    I'll fix it tomorrow, sorry about that

  • also, if they are multiple instances of the same spritefont object

    how are you picking the individual ones

    is it by private variable in the spritefont?

    [edit]

    hmmm...not getting it to happen for me:

    http://dl.getdropbox.com/u/1013446/multitest.cap

    left click changes one of the texts, right click changes the other, middle click destroys the two one by one

    also, link on first page has slightly updated version of plugin

    fixes a small bug or two

  • when did it stop working?

    when you updated spritefont to a new version?

    or when construct changed to a new version?

    also, are you setting the letters with Set By String, or Set Range?

  • interesting konjak

    I was just working on a project yesterday

    something to help people memorize stuff for my job

    but it involved text coming from arrays as well

    and it works totally fine, and then I'd add a text object, or add an item to the array

    and then it would crash, and even if I changed it back it would crash

    I'll look into this anyway, but maybe there's some problem with text and arrays in general

  • ill respond and update when i have a little more time,

    but dataflash, you can do that either by:

    to get the difference between 5 and thatvar

    distance(5,0,thatvar,0)

    or more simply:

    abs(5-thatvar)

    or

    abs(thatvar-5)

  • > +Pick BlueFamily in vector
    -Destroy Sprite
    [/code:2bops2pj]
    

    this would work no matter what, since family and object picking are separate, so the plugin isn't doing anything

    [quote:2bops2pj]

                if ((*i) == begin)
                {
                      pRuntime->SelectAll((*i)->pType);
                      pRuntime->SelectF((*i), (*i)->pType);
                }
          }
    }
    [/code:2bops2pj]
    
    each time you call SelectAll((i*)->pType), if that type was already selected before, you're basically undoing the selection and starting over, so in the end, only the very last of each type that was picked in this manner would be picked
    
     I think you need to use the isFamily and GetFamilyTypes functions
    [code:2bops2pj]	if(objType->IsFamily)
    	{
    		pRuntime->GetFamilyTypes(objType,Types,count) ;
    		//loop through Types with iterator i;
    		for (i is less than size of types)
    		{
    			getInstances of i;
    			selectall of i;
    			for (each instance of i)	
    			{
    				if (instance is in vector)
    					select instance;
    			}
    		}
    	}
    	else
    	{
    		pRuntime->SelectAll(objType)
    		get instances of objType
    		for (each instance)
    		{
    			if (instance is in vector)
    				select instance;
    		}
    	}[/code:2bops2pj]
  • with some math you could add dampening by adding angular force in the opposite direction each tick depending on the current angular speed

  • Don't wanna hijack this thread but it'd also be great to have:

    1) Simulate events.

    If global('Cutscene01') is on, Player walks to X, Y, etc.

    If Cutscene 01 is on and player is at X, Y, play animation blabla.

    It'd be freaking great being able to simulate the platform behavior for Cutscenes.

    with the custom controls object (I think the mouse/keyboard one might work now, too, it might still be broken) you can simulate controls by using the SetControlState actions

    like

    -Set Control State ("jump",1)

    would be like the player pressed the jump button

  • pType will always return the specific type of the object

    I haven't tried this before, but it looks like you would have to do:

    if(objType->IsFamily)
          pRuntime->GetFamilyTypes(objType,...,...)  //read the comments for more info on this function[/code:5daw4gzy]
  • what aritz is saying is that if he has several different objects on layer 1, you would need to do that condition for each type

    but it couldnt really work

    'for each' conditions pick the objects one at a time

    for each object would present the problem that there isnt actions for objects in general.

    if you have sprite1, and sprite2 on layer1

    you cant say Set object position to 1

    the only way to do it would be families, which would work with the current method the devs mentioned

    even a hypothetical object action couldnt really work, since you could say set object position to sprite1, and sprite1 might already be the current object picked

  • damnit! i thought the crash art was hilarious, and i was even considering if it was possible to make it crash that way way on purpose so i could make the crash art plugin, and now i just noticed the spritefont folder on that screenshot, so maybe i already have

lucid's avatar

lucid

Member since 16 Jan, 2009

Twitter
lucid has 22 followers

Connect with lucid

Trophy Case

  • 15-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
  • Coach One of your tutorials has over 1,000 readers
  • RTFM Read the fabulous manual
  • Email Verified

Progress

22/44
How to earn trophies