Can someone please help me out

Discussion in 'CommandHelper Scripts' started by Phantomized, Nov 16, 2015.

  1. Phantomized

    Phantomized New Member

    I am learning commandhelper and methodscript... I want to learn it well and I have been able to make these commands so far. I have been learning for a day and a half but unfortunatly the video series ended early on which helped my learn it and there are no more english videos available to teach me. Could someone give me or direct my some scripts you or others have created which isn't too complex and something I could learn, understand and edit to improve my skills with commandhelper. Thank you

    (this is what I have done so far, nothing logical or in logical order just testing things out)

    *:/welcome = >>>
    @varnotben = 'You are not worthy to be in the presence lord ****imus. Be gone!';
    @varben = 'Welcome Lord ****imus!';
    if (player() == 'Combat_Wombat')
    {
    run('/give '.player().' 122 64');
    run('/give '.player().' 276 64');
    broadcast(@varben);
    }
    else{
    run('/give '.player().' 367 64');
    broadcast(@varnotben);
    }
    <<<

    #The code above identifies if a player is ben or not. If he/she isn't ben, they will be given a stack of rotten flesh and told 'You are not worthy to be in the presence lord ****imus. Be gone!'. But if you are ben, you will be given a stack of diamonds swords and ender eggs and be welcomed a lot nicer [​IMG]

    *:/kit mlgop = >>>
    run('/give '.player().' 122 64');
    run('/give '.player().' 276 1');
    <<<

    just a kit command I created for testing

    /kit gold = >>>
    run('/give '.player().' 284 64');
    run('/give '.player().' 285 64');
    run('/give '.player().' 286 64');
    <<<

    *:/cooltp $name = >>>
    set_ploc(
    ploc(
    player($name)
    )
    )
    broadcast('Teleporting you to' $name)
    <<<
    #Tphere and tp commands I created
    *:/cooltphere $name = >>>
    set_ploc(
    player($name),
    ploc()
    )
    broadcast('Teleporting' $name 'to you')
    <<<

    *:/amicool = >>>
    if(player() == pisop())
    {
    broadcast('cuz your op your cool');
    }
    else{

    broadcast('your not op so your not cool');
    }

    <<<

    #The command /amicool determines if you are op on the server or not, and tells you if you arn't cool because you arn't op.



    These are all on my own localhost server.. Not the actual server :p



    bind(entity_explode,null,null,@p) {
    modify_event ('yield', 0)

    }



    #My most complex piece of script, yes, shorter than most of them but believe it or not it is more complex in my opinion :p. I changed the percentage of how many drops are given that creepers blow up. Set at 0 so no drops will be there [​IMG]



    I
  2. PseudoKnight

    PseudoKnight Well-Known Member

  3. Phantomized

    Phantomized New Member

    Yeah, the learning trail wasn't great in my opinion. It's not how I learn things and I think the wiki as a whole isn't beginner friendly. I'm teaching myself to script to help out our other scripter on our very popular survival server, some things he had scripted are ingame reporting (very well made),
  4. PseudoKnight

    PseudoKnight Well-Known Member

    Huh. Every time I look through the Learning Trail I'm always surprised how informative it is, especially compared to other documentation you typically see. It could use some updates but it's not fundamentally flawed. Not sure what could make it more beginner friendly, though. Maybe some more practical scripts throughout?
  5. Phantomized

    Phantomized New Member

    Informative, yes.. But looking at it from a beginners point of you can just make you go "wat".. I think more interactivity and explaining of terms at first would be better.
  6. PseudoKnight

    PseudoKnight Well-Known Member

    Interactivity... like expandable sections and hover descriptions, maybe?
  7. MCmacjuul

    MCmacjuul Member

    There are people I'm teaching CH and I sent them to read the learning trail. They got the idea what it's all about but there where some parts they did not understand , like "why you write something in a certain way" and "what exacly does this do". I do agree the learning trail is pretty informative but I think it could be expanded here and there. Don't forget that a lot of people who get CommandHelper don't even know how to program at all.

    A big problem I see for the people I'm learning CommandHelper to is "what goes where". Maybe a "step by step guide to making your first script" would help with that, and show them how to construct the scripts. In that step-by-step guide it could also introduce you to some important functions like if and msg.

    On the end I feel like the learning trail does do a great job for new people who have coding experience, but for non-coders it's still very vague. I often end up explaining most things on the learning trail again to the people I teach.

    One part on the learning trail I find very unclear. The first page shows you how to make aliases and this teaches you different things than the rest of the trail does, since the rest is more about MethodScript itself. The aliases page explains some new syntaxes for aliases but it doesn't have any real big use for real scripts, and in my point of view only makes it a little more confusing about what an alias is and what a script it. I'd say the part that explains the differences with simple aliases and bigger scripts should be expanded on since currently the transition from aliases to scripting is a little confusing for some people.

    The suggestion about making hover tooltips are a good idea. It would be great if all functions used in the trail would have a tooltip with a small description and clicking them would take you to the Staged API page of that function
    Last edited: Nov 21, 2015
  8. TampGames

    TampGames New Member

    So, as Macjuul was saying. When I started learning (under him) I was referred to the Learning Trail. The beginners guide really helps a lot if you're new which I am. I wish in the boxes of code it would explain what each variable did like:

    $var1 = 2 //Variable 1 is equal to two
    msg($var1) //msges player the variable which equals to two

    That's what I would like because I ended up asking Mac all these questions that I could've learned from the guide. I understand some concepts like strings and doubles and such due to having a little background in Java and Python and a tiny tiny bit of swift. I wish my example above would really be added because when you just put a huge array down, I don't get what's going on and it makes me really confused on how its going to work.

    Like what Mac said above, It would be really handy to have a guide that helps you construct your first script. It could be something as simple as a kit (I had a hard time getting that one down) or something a little more complex like a chat filter that takes out one bad word.

    A few things I still don't understand is proc() and bind() Guess il have to ask mac soon.
  9. sebdomsan54

    sebdomsan54 Member

    The way that i have learned most of this language was out of ideas that my friends wanted to see or i wanted to see and then i would look trough the wiki for a lead on how to do something but if this is your first coding language i wouldn't start here only due to the small community witch is great but the documentation can fall short sometimes and you need alot of help on those kinds of things if this is your first language i learned batch before i came to this but scratch dose a great job of teaching coding logic witch helps when you get stuck on how many steps you will need
  10. Phantomized

    Phantomized New Member

    I know this is a long shot... But videos would be amazing help to learn... Have you ever considered making any?
  11. PseudoKnight

    PseudoKnight Well-Known Member

    VergilPrime has made some videos, but you can't update videos, collaborate on them, scan them, etc. They're just much harder to work with in ALL ways.







    I'll give it some thought, but I'm not sure it'd be a good use of my time -- mostly because I'd want to do it right.