Author Topic: Help with C++  (Read 10379 times)

0 Members and 1 Guest are viewing this topic.

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Help with C++
« Reply #15 on: October 22, 2011, 02:52:24 pm »
have you not seen it?  It was my first axe game <3


Note: I have changed it since, and mass optimized for speed.  (lol should probably take out of Full speed now :P )
         
« Last Edit: October 22, 2011, 02:56:15 pm by Happybobjr »
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Help with C++
« Reply #16 on: October 22, 2011, 03:04:22 pm »
have you not seen it?  It was my first axe game <3


Note: I have changed it since, and mass optimized for speed.  (lol should probably take out of Full speed now :P )
         

Of course I know it, go check the topic, I was super excited about the game at the time :D

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Help with C++
« Reply #17 on: October 22, 2011, 03:06:33 pm »
Wow i was such a noob back then.
The biggest day of my life... when I realized how slow displaying the graph is :P
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Help with C++
« Reply #18 on: October 29, 2011, 02:31:55 pm »
In axe we can use Pt-On(x,y,Pic1)
How can I do that in C++.
I am using SDL
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline Munchor

  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 6199
  • Rating: +295/-121
  • Code Recycler
    • View Profile
Re: Help with C++
« Reply #19 on: October 29, 2011, 02:38:29 pm »
In axe we can use Pt-On(x,y,Pic1)
How can I do that in C++.
I am using SDL

Try this. I found it through Google, a very useful website!

Offline Happybobjr

  • James Oldiges
  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2325
  • Rating: +128/-20
  • Howdy :)
    • View Profile
Re: Help with C++
« Reply #20 on: October 29, 2011, 02:40:03 pm »
lol.  I asked here because I am very fluent in axe, so i thought you guys may be able to explain it better to me than other people :/
School: East Central High School
 
Axe: 1.0.0
TI-84 +SE  ||| OS: 2.53 MP (patched) ||| Version: "M"
TI-Nspire    |||  Lent out, and never returned
____________________________________________________________

Offline Scipi

  • Omni Kitten Meow~ =^ω^=
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1547
  • Rating: +192/-3
  • Meow :3
    • View Profile
    • ScipiSoftware
Re: Help with C++
« Reply #21 on: October 29, 2011, 04:14:27 pm »
It seems like in SDL, as in SFML, you need a pointer to the image. You take that pointer and use SDL_BlitSurface() like so:

param1: pointer to image

param 2: Rect image is stored in

param3: pointer to screen

param4: Rect with x,y coords of where to draw to the screen.

SFML, I think, has an easier drawing method of:

Code: [Select]
sf::RenderWindow App(sf::VideoMode(WindowWidth, WindowHeight, 32), "title");

sf::Image img;//Image data
img.LoadFromFile("img.png");
sf::Sprite imgSprite(img);//Pointer to data
imgSprite.SetPosition(x, y)

App.Draw(imgSprite)

Imma Cat! =^_^= :3 (It's an emoticon now!)
Spoiler For Things I find interesting:
Spoiler For AI Programming:
Spoiler For Shameless advertising:

Spoiler For OldSig:





Spoiler For IMPORTANT NEWS!:
Late last night, Quebec was invaded by a group calling themselves, "Omnimaga". Not much is known about these mysterious people except that they all carried calculators of some kind and they all seemed to converge on one house in particular. Experts estimate that the combined power of their fabled calculators is greater than all the worlds super computers put together. The group seems to be holding out in the home of a certain DJ_O, who the Omnimagians claim to be their founder. Such power has put the world at a standstill with everyone waiting to see what the Omnimagians will do...

Wait... This just in, the Omnimagians have sent the UN a list of demands that must be met or else the world will be "submitted to the wrath of Netham45's Lobster Army". Such demands include >9001 crates of peanuts, sacrificial blue lobsters, and a wide assortment of cherry flavored items. With such computing power stored in the hands of such people, we can only hope these demands are met.

In the wake of these events, we can only ask, Why? Why do these people make these demands, what caused them to gather, and what are their future plans...