• Welcome to Smashboards, the world's largest Super Smash Brothers community! Over 250,000 Smash Bros. fans from around the world have come to discuss these great games in over 19 million posts!

    You are currently viewing our boards as a visitor. Click here to sign up right now and start on your path in the Smash community!

Project M Social Thread Gold

Helsong

Smash Ace
Joined
Mar 31, 2015
Messages
899
Location
Helsy Helsy Helsy
it works if i directly set the root. root is a global variable of the SplayTree object. doing something like root = rotateRight(root); affects the tree just fine.

my splay function takes in a node. doing something like node = rotateRight(node); does not affect the tree

my rotateRight method:
Code:
private SplayNode<E> rotateRight(SplayNode node) {
     SplayNode tmp = node.getLeft();
     node.setLeft(tmp.getRight());
     tmp.setRight(node);
     node.setParent(tmp);
     return tmp;
   }
The returned node from rotateRight is exactly what i need to set the passed in node to
Dumb Questions continued: Are you changing the tree when you do rotateRight(node)? after all, since root is a global variable(I'm assuming referencing the root of the splay tree), then root=rotateRight(root); would work, given that your method is working as it should. Sounds like it is.
So, I'd imagine the problem is that using node = rotateRight(node); doesn't actually touch the tree itself, but rather just a node object that's a copy of a part of the tree? You may need to reference the tree using root to affect the tree itself. Finding the node you want to change and then sending in that node doesn't quite work, as you're then sending in a node that's a copy of that section of the tree, not the tree itself. At least, that's my best guess.

@ eideeiit eideeiit I've been there too. It wasn't until I found coding that I really understood what I wanted to do with my life. Keep looking and don't give up!
 
Last edited:

standardtoaster

Tubacabra
Joined
Nov 26, 2009
Messages
9,253
Location
Eau Claire, Wisconsin
yeah that's exactly what's happening. it's affecting a copy of the section of the tree and not the tree itself. if i can't get it working today then i guess i'll just ask my prof during office hours tomorrow :/


this is literally the one time where i'd want to use C++ so i can directly affect the pointer/reference instead of java just making copies lol
 
Last edited:

Helsong

Smash Ace
Joined
Mar 31, 2015
Messages
899
Location
Helsy Helsy Helsy
Welcome to Java, haha. Why not try sending in the node by doing something like: rotateRight(root.left.left.right.whatever);? Reference the node you're looking at via the global variable.
 

drakargx

Smash Journeyman
Joined
Feb 28, 2015
Messages
348
In Java since everything is a class there aren't globals per say because variables have to be connected to a instance of an object

You can make variables static and shift the connection to be class specific, which is why you can type Math.PI and get access to the pi constant without having to make a math instance

In the OOP world globals are very nasty but there are some situations where you can't get by without them
 

Gamegenie222

Space Pheasant Dragon Tactician
Joined
Mar 18, 2008
Messages
6,758
Location
Omaha, Nebraska
NNID
Gamegenie222
3DS FC
3411-1825-3363
I've drawn for fun for ~13 years now and all I have to show for it are countless doodles of eyes and unbelievably ugly men on every frigging page of every notebook and school book with the exception of maths. Every time I see someone show their actually good drawings I get jealous and wish I could do the same and draw "for realz" for about 10 mins but then realize that it'd take work and dedication and give it up.

The moral of the story naturally being: give up before trying, it'll save you the effort and lets you waste your time in more useless ways.

But really, I'd say it's never too late

Also that feel when you try to escape reality to the internet but the social thread is filled with people that actually know what to do with their lives. ;_;
Yeah I hear you on that. Ironically enough I enjoyed art classes and museums during my school years excluding College. Stuff like clay pottery and such with calming music I enjoyed alot but I'm terrible at coming with ideas for papers, pottery and paintings a majority of the time and it irks me so.
 

Helsong

Smash Ace
Joined
Mar 31, 2015
Messages
899
Location
Helsy Helsy Helsy
In Java since everything is a class there aren't globals per say because variables have to be connected to a instance of an object

You can make variables static and shift the connection to be class specific, which is why you can type Math.PI and get access to the pi constant without having to make a math instance

In the OOP world globals are very nasty but there are some situations where you can't get by without them
Aww yeah baby, keep talking dirty.

(This was mildly helpful in patching some holes in my understanding of how Java does this stuff. Thanks.)
 
Last edited:

standardtoaster

Tubacabra
Joined
Nov 26, 2009
Messages
9,253
Location
Eau Claire, Wisconsin
Yes, I did this because I was bored and tired of splay trees not working out.

Global variables are just variables that you set outside of any method. They can be public or private depending on what you want to do with them. I was always taught to use private variables and getters/setters for them inside of objects.

Let's say you had a simple object like this:

Code:
public class RyuukoMatoi {
// variable
  private boolean foundWay;

// constructor
public RyuukoMatoi() {
  foundHerWay = false;
}

// methods
//setter
public void foundHerWay() {
// set foundWay to true
// she found her way, go ryuuko!
  foundHerWay = true;
}
/getter
public boolean getWay() {
  return foundWay;
}
If you wanted to get access to foundWay you would need to make an instance of the object and then use the getWay method to get foundWay. If you didn't want to use a getter you could make foundWay a public variable.

Code:
public class KillLaKill {
  public static void main(String[] args) {
  RyuukoMatoi ryuuko = new RyuukoMatoi();
  System.out.println(ryuuko.getWay()); // prints false
  ryuuko.foundHerWay();
  System.out.println(ryuuko.getWay()); // prints true

  // if foundWay was public you could do
  System.out.println(ryuuko.foundWay); // prints false
  ryuuko.foundWay = true;
  System.out.println(ryuuko.foundWay); // prints true
  }
}
 
Last edited:

drakargx

Smash Journeyman
Joined
Feb 28, 2015
Messages
348
Aww yeah baby, keep talking dirty.

(This was mildly helpful in patching some holes in my understanding of how Java does this stuff. Thanks.)
I was going to type a post with sexual implications but I forgot the first half as I was thinking of the second half

On a completely related note, getters and setters give me ptsd and I wish every language was like C# where I could just do
Code:
private int x { get; set; }
And be done with getter/setter for that variable
 

trash?

witty/pretty
Premium
Joined
Jul 27, 2012
Messages
3,452
Location
vancouver bc
NNID
????
I made a huge postmortem post in the SSBB boards and I don't... really know why. I guess it's because it's a year after people were talking about how brawl will do just fine without new ruleset changes, and now the board is just a handful of wi-fi players wondering why nobody plays the game anymore

http://smashboards.com/threads/is-brawl-dead.399287/#post-19048718

realtalk: I'm all for letting the metagame play a centralized character out, but even then, MK should have been banned by 2010 at the latest. it was pretty clear from anyone even remotely competent in understanding metagames that he was devolving more than evolving, which is the most important factor in justifying a ban
 

eideeiit

Smash Ace
Joined
May 14, 2014
Messages
592
Location
Finland, Turku
Yeah I hear you on that. Ironically enough I enjoyed art classes and museums during my school years excluding College. Stuff like clay pottery and such with calming music I enjoyed alot but I'm terrible at coming with ideas for papers, pottery and paintings a majority of the time and it irks me so.
I've heard that some people carry a notebook (idk, a phone could work) with them at all times and whenever the inspiration hits them but they don't have their kit or whatever they jot it down to make remembering it later easier.

Personally I also think that creativity is not always necessary. Just copying others to the best of your ability can be quite fun sometimes.
 

Helsong

Smash Ace
Joined
Mar 31, 2015
Messages
899
Location
Helsy Helsy Helsy
I was going to type a post with sexual implications but I forgot the first half as I was thinking of the second half

On a completely related note, getters and setters give me ptsd and I wish every language was like C# where I could just do
Code:
private int x { get; set; }
And be done with getter/setter for that variable
I KNOW RIGHT?! Seriously, I'm so glad eclipse has options to generate them for you in Java, but it's just a pain. I code so that I can automate repetitive tasks, not so I have to keep doing them, dammit.
There's an innuendo to be made in there somewhere, but getters and setters are the biggest turn off in all of CS ever.
 

steelguttey

mei is bei
Joined
Mar 25, 2014
Messages
1,674
I made a huge postmortem post in the SSBB boards and I don't... really know why. I guess it's because it's a year after people were talking about how brawl will do just fine without new ruleset changes, and now the board is just a handful of wi-fi players wondering why nobody plays the game anymore

http://smashboards.com/threads/is-brawl-dead.399287/#post-19048718

realtalk: I'm all for letting the metagame play a centralized character out, but even then, MK should have been banned by 2010 at the latest. it was pretty clear from anyone even remotely competent in understanding metagames that he was devolving more than evolving, which is the most important factor in justifying a ban
honestly i couldnt have said it better

mk shouldnt have been banned because of the character himself, he shouldve been banned because the amount of the game he limited

a good example of this is (oh boy pokemon) talonflame in the oras metagame. if you look at BL, nearly hafl of it is people that are there simply because talonflame checks them. he shouldnt be uber because hes impossible to beat, he should be uber because the amount of influence he has on the meta
 

trash?

witty/pretty
Premium
Joined
Jul 27, 2012
Messages
3,452
Location
vancouver bc
NNID
????
well, mass-influence doesn't have to be a bad thing, keep in mind. a game like melee is inherently centralizing in nature, and if you ask a melee purist, they enjoy that. while I, personally, wouldn't play full-time in such a metagame, I can see why people love it so much, as it focuses on a handful of characters, which means their specific metagames get stretched out far more efficiently.

metaknight, though, was a very bad form of influence; whereas a metagame based around the big four in melee leads to interesting picks and cores, say, a metagame based around metaknight led to a toxic, little-committed playstyle, which led to players attempting to limit it, and that limiting then led to a just-as-toxic ice climbers suddenly being OP with no bad stages around
 
Last edited:

Gamegenie222

Space Pheasant Dragon Tactician
Joined
Mar 18, 2008
Messages
6,758
Location
Omaha, Nebraska
NNID
Gamegenie222
3DS FC
3411-1825-3363
I made a huge postmortem post in the SSBB boards and I don't... really know why. I guess it's because it's a year after people were talking about how brawl will do just fine without new ruleset changes, and now the board is just a handful of wi-fi players wondering why nobody plays the game anymore

http://smashboards.com/threads/is-brawl-dead.399287/#post-19048718

realtalk: I'm all for letting the metagame play a centralized character out, but even then, MK should have been banned by 2010 at the latest. it was pretty clear from anyone even remotely competent in understanding metagames that he was devolving more than evolving, which is the most important factor in justifying a ban
You probably did it to inform the new heads as to why Brawl died as Canada do have the only scene left for the game for what I'm aware of. The massive screw up and flub that we did and the stigma behind the game drowned it into the abyss even further and new players don't know why the game was massively hated in full detail outside of what they heard from the smash doc. Stigma is still lingering toward some it carries over to Smash 4 a little bit as well. Not all Brawl players went to Smash 4 though as I know Praxis don't like the game as well as Mike Haze and Anti trolls the crap outta the game from time to time on FB and I met Lain a while ago(old school Brawl IC player) and asked him if he's playing smash 4 and he's like nope I've seen it and played Brawl for years and not gonna through that again LMAO. It's disheartening to see it happen and explain it to new heads why we ****ed up.

EDIT: Reminded me lol I just seen this yesterday and just saw the comments.
 
Last edited:

trash?

witty/pretty
Premium
Joined
Jul 27, 2012
Messages
3,452
Location
vancouver bc
NNID
????
smash 4 will probably end up better, I think. while in theory, the decisions are a lot more simplistic and linear, it still actually wants you to do things, even if that thing is "sit on the other side of the screen and toss items" like the campier top tiers are like in that game.

like, that's something I need to constantly keep in mind when talking about brawl. it didn't devolve into being too defensive or too campy, because being "too defensive or too campy" implies there's things actually being done. late game brawl was all about doing as little as you possibly could.
 

Gamegenie222

Space Pheasant Dragon Tactician
Joined
Mar 18, 2008
Messages
6,758
Location
Omaha, Nebraska
NNID
Gamegenie222
3DS FC
3411-1825-3363
Hopefully so but we're heavily into the stream monster age so if a major tourney like EVO happens and it's top 8 is boring then that hurts the image for the game lol.

Also WTF Lylat this is PKMN Stadium 1 type glitchness in Brawl.

EDIT:
 
Last edited:

steelguttey

mei is bei
Joined
Mar 25, 2014
Messages
1,674
playing smash 4 kills me slowly

the ledge mechanics in that game are just awful

they took a perfectly fine mechanic that has had 12 years of meta development around it and threw it out the window because you should apparently always get back on stage
 

Player -0

Smash Hero
Joined
Jun 7, 2013
Messages
5,125
Location
Helsong's Carpeted Floor
Only problem with using something like Brawlbox to rig models is that proportions and stuff might be different and some stuff exaggerated. Might just try to take a picture of myself, the pose will be extremely hard to take a picture of though lol
 

Hinichii.ez.™

insincere personality
Joined
Nov 2, 2013
Messages
4,290
NNID
hinichii
3DS FC
2423-5382-7542
playing smash 4 kills me slowly

the ledge mechanics in that game are just awful

they took a perfectly fine mechanic that has had 12 years of meta development around it and threw it out the window because you should apparently always get back on stage
I have found ways to make it work in my favor
I play sonic and i rekt n00bs with the trumpet
 

trash?

witty/pretty
Premium
Joined
Jul 27, 2012
Messages
3,452
Location
vancouver bc
NNID
????
playing smash 4 kills me slowly

the ledge mechanics in that game are just awful

they took a perfectly fine mechanic that has had 12 years of meta development around it and threw it out the window because you should apparently always get back on stage
in nintendo's defense, ledge trumping is objectively better than brawl's ledge mechanics

I think I've only ever seen one time in my life where someone got a ledgehog in brawl. and that was in a combo video, so
 

Lizalfos

Smash Master
Joined
Dec 30, 2013
Messages
3,483
Location
Greenville, SC
I want to do ink drawings like the MGS art.
One day I'll write mind**** code where the getter is private and the variable is public.
 

Gamegenie222

Space Pheasant Dragon Tactician
Joined
Mar 18, 2008
Messages
6,758
Location
Omaha, Nebraska
NNID
Gamegenie222
3DS FC
3411-1825-3363
playing smash 4 kills me slowly

the ledge mechanics in that game are just awful

they took a perfectly fine mechanic that has had 12 years of meta development around it and threw it out the window because you should apparently always get back on stage
Cause most kids should get happy meal toy ledges. At least it nerfed planking and ledgestalling a little bit.
 

steelguttey

mei is bei
Joined
Mar 25, 2014
Messages
1,674
in nintendo's defense, ledge trumping is objectively better than brawl's ledge mechanics

I think I've only ever seen one time in my life where someone got a ledgehog in brawl. and that was in a combo video, so
i mean the ledge mechanics would be fine if the ledge grab boxes werent ****ing insane
 

PMS | Tink-er

fie on thee
Joined
Apr 2, 2014
Messages
3,172
Location
Tampa, FL
NNID
emptymetaphor
3DS FC
1337-1337-1337
OK : D I haven't done much lately, at least outside of figure drawings like that. School plus trying to finish 3dmaneuvering props in time for akon, along with my side project (what all the figure drawings are for) doesn't leave too much extra time.

In other news: this is why I remain ever mediocre at smash : p all my spare time for practice tends to fall away : /
well, I pretty much just do stuff for fun /hobby, myself. It's just about how much spare time you have and what you prioritize. Nothing wrong with putting other things ahead of it.
I pitched an idea on the slack a month or two ago and everyone seemed interested, but I'm not sure how to go about showing off the whole moveset. Also my drawings suckkkkkkk. H how do you do it oh great master.
 

Motobug

Project M/+ community leader
Joined
Jun 26, 2013
Messages
257
Location
Massachusetts
smash 4 will probably end up better, I think. while in theory, the decisions are a lot more simplistic and linear, it still actually wants you to do things, even if that thing is "sit on the other side of the screen and toss items" like the campier top tiers are like in that game.

like, that's something I need to constantly keep in mind when talking about brawl. it didn't devolve into being too defensive or too campy, because being "too defensive or too campy" implies there's things actually being done. late game brawl was all about doing as little as you possibly could.
Wasn't there a brawl match where M2K and an ICs player just stood around on Smashville for a whole minute?
Yea, good times...

Anyway
finally got around to watching KLK
I'm glad I did (and I finished like 8 episodes in a few hours. Halp)
 
Top Bottom