Author Topic: READ BEFORE POSTING: Some useful Squirrel scripting links  (Read 3935 times)

0 Members and 1 Guest are viewing this topic.

Offline m0niSx

  • Master
  • ***
  • Posts: 626
  • Life is good
    • View Profile
    • IV:MP
Re: Some useful Squirrel scripting links
« Reply #15 on: January 17, 2010, 02:38:19 PM »
Will be functions to read/write INI files or will be converted Dini from Pawn?
I'll create a code to read/write from ini files
Birthday 16h July :)

Offline Almamu

  • Newbie
  • *
  • Posts: 5
    • View Profile
    • Games Fun Inc
Re: Some useful Squirrel scripting links
« Reply #16 on: January 17, 2010, 02:39:59 PM »
Will be functions to read/write INI files or will be converted Dini from Pawn?
I'll create a code to read/write from ini files
ok, thanks, i'm learning squirrel syntaxis(i was programing in pawno for SA:MP)
EDIT: I'm having some problems installing it on Eclipse
When i Start a New Project it returns a error: Build Squirrel Error
« Last Edit: January 17, 2010, 02:56:15 PM by Almamu »
You will need a god, but when that happens there will be none, then there is only one thing, Survive
(c)CopyRight Almamu 2010

Offline Trucker

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #17 on: January 20, 2010, 07:53:26 PM »
Short question:
Code: [Select]
    if(cmd[0] == "/waffe")
    {
        if(cmd[1] && cmd[2] && cmd[3])
        {
            if(IsPlayerConnected(cmd[1])){
                AddPlayerWeapon(cmd[1], cmd[2], cmd[3])
SendPlayerMessage(cmd[1], COLOR_RED, "SERVER: ["playerid"]"+GetPlayerName(playerid)+" has sent you a weapon. WeaponID: (" + cmd[2] + "); Ammu: (" + cmd[3] + ")");}
else{
                SendPlayerMessage(playerid, COLOR_RED, "SERVER: No player found!");            }}
    }
Will this work in IV:MP 0.1? :S

Offline iker29th

  • Newbie
  • *
  • Posts: 7
  • 1337 Playa
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #18 on: January 29, 2010, 01:21:22 PM »
great, I'm glad to see that scripting in IV:MP won't be too different from the SA:MP type, I'll start scripting my own gamemode soon.

it'll probably be a DM/TDM one 8D


SA-MP Player Since September '07;
Windows Live Gamertag: iker29th;
PWNO Scripter;

Offline [___]Whitetiger

  • Regular
  • **
  • Posts: 366
    • View Profile
    • sampcommunity.com
Re: Some useful Squirrel scripting links
« Reply #19 on: January 30, 2010, 01:07:32 AM »
great, I'm glad to see that scripting in IV:MP won't be too different from the SA:MP type, I'll start scripting my own gamemode soon.

it'll probably be a DM/TDM one 8D

ill be there ;)

Offline Sebihunter

  • Administrator
  • ******
  • Posts: 393
  • [gerG] since 2006
    • View Profile
    • Sebihunter.de
Re: Some useful Squirrel scripting links
« Reply #20 on: February 01, 2010, 10:59:25 PM »
for anyone who hasn't noticed: There are some changes in our scripting system.

There are now some more funcs and callbacks. Also funcs and callbacks now begin with a low-case letter and not a high-case one.

Quote
#ivmp IRC
(22:01:15) (Mistrzu4_ivmp) where is janksta?
(22:01:58) (IksDe_ivmp) ...?
(22:02:22) (Mistrzu4_ivmp) In toilet?

Offline Trucker

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #21 on: February 02, 2010, 06:36:29 PM »
Ah, nice. More functions :)
Is there any reason for the letter-case change?

Offline Don Correlli

  • Regular
  • **
  • Posts: 114
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #22 on: February 02, 2010, 06:49:02 PM »
Ah, nice. More functions :)
Is there any reason for the letter-case change?

So the functions and callbacks won't look like SA:MP ones probably. MTA is also using low-case letter for functions and callbacks.

Offline jenksta

  • Administrator
  • ******
  • Posts: 240
  • Lead Developer
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #23 on: February 02, 2010, 08:44:26 PM »
Ah, nice. More functions :)
Is there any reason for the letter-case change?
Because i don't want it to be too much like sa-mp.
Quote from: #ivmp
<TrojaA> Pyrokid also in programmin gnad that fuck.. bitch @m0niSx you make me sick.

Offline VRocker

  • Newbie
  • *
  • Posts: 5
    • View Profile
    • Liberty Unleashed
Re: Some useful Squirrel scripting links
« Reply #24 on: February 03, 2010, 01:08:59 AM »
Nice to see you using squirrel :) tis a great language.

Noticed your using the old SetPlayerHealth( playerid, <health> ) though, why not export the classes to squirrel so instead of passing a playerid to the callbacks, pass a pointer then do player.Health = <health>;

Its much nicer, easier and more efficient i've found. It also makes it more unlike samps scripting :)

Offline jenksta

  • Administrator
  • ******
  • Posts: 240
  • Lead Developer
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #25 on: February 03, 2010, 06:02:23 AM »
Nice to see you using squirrel :) tis a great language.

Noticed your using the old SetPlayerHealth( playerid, <health> ) though, why not export the classes to squirrel so instead of passing a playerid to the callbacks, pass a pointer then do player.Health = <health>;

Its much nicer, easier and more efficient i've found. It also makes it more unlike samps scripting :)
Well i havn't really thought about that.
However id much rather have the scripters create thier own classes.
Quote from: #ivmp
<TrojaA> Pyrokid also in programmin gnad that fuck.. bitch @m0niSx you make me sick.

Offline Paulo_Henrique

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #26 on: February 11, 2010, 06:23:52 PM »
Squirrel it´s very easy, it´s like of the syntax of pawn code.




Offline SolidSnake

  • Newbie
  • *
  • Posts: 2
  • ITS Time You Saw The Future
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #27 on: April 04, 2010, 12:40:36 AM »
its very useful

Offline John_Cena

  • Newbie
  • *
  • Posts: 25
    • View Profile
Re: Some useful Squirrel scripting links
« Reply #28 on: April 05, 2010, 01:43:56 PM »
Squirrel it´s very easy, it´s like of the syntax of pawn code.
I already find it very difficult Squirrel

Offline Cameron (No1Servers.com)

  • No1servers owner
  • Administrator
  • ******
  • Posts: 144
  • No1servers owner
    • View Profile
    • No1Servers
Re: Some useful Squirrel scripting links
« Reply #29 on: April 05, 2010, 08:41:00 PM »
Squirrel it´s very easy, it´s like of the syntax of pawn code.
I already find it very difficult Squirrel
Its not that different, download the latest IVMP and take a look at some of the demo scripts :) you will see how it all works! :D