drawing polygons like sprite object

This forum is currently in read-only mode.
From the Asset Store
You need this package if you want to program a Street Fighter or battle game.
  • I've been trying to extract what I need from the sprite plugin, but nothing seems to work

    I tried something as simple as:

    renderer->setTexture(image);

    renderer->Quad_xywh(50,50,100, 100);

    and that doesn't work

    I also tried copypasting renderdistorted(...)

    but using my own distortion values, and nothing I draw renders anything to screen at all

    let's say I just want to draw a triangle at 3 points(x,y,u,v),

    p1,p2,p3

    and I have TextureHandle image;

    what do I need to do? bare minimum to get a triangle on screen,

    any help would be appreciated

    if it matters for now, I'm getting image by :

    :

    param[0].GetParamFirstInstance(pRuntime)->info.CurTexture

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Are you checking 'image' is not null? Otherwise AFAIK it'll just draw a white solid fill box. SetTexture and a Quad are all you need to get a texture on the screen though.

    (Note you should always check for NULLs - don't assume GetParamFirstInstance returns an instance - what if there are no instances?)

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