1. Post #401
    LaughingLeader's Avatar
    July 2011
    19 Posts
    The thing is, this aren't Tiramisu questions, these are actual general gamemode questions. In ALL gamemodes, you have to drop the actual SWEPs on entities/weapons, inside the root gamemode folder. In the case of Tiramisu that is gamemodes/tiramisu/entities/weapons. Drop them in a folder named like your SWEP's class.

    Now, the gamemode CAN access your SWEP, but if you want it to work with the inventory system, you'd have to make an item, with the same class name as your SWEP. Making an item is as straightforward as Matt posted above. Why don't I document this? One, items are mostly self explanatory, two, it's the same system that exists in Cakescript G2, three, you can actually make new items in game anyway.

    So the answer ain't vague, it's exactly correct.
    I've tried that, actually. I threw the rcs_base and the rcs_ump into the entities/weapons, then created the item code in the /items/ folder, and gave it the same class name. Yet, I must be missing something, as all it did was make the gun disappear when I tried to "use" it, and it wasn't in my weapon scroll menu.

    What goes into the item code that makes it point at the entites/weapons/ folder and links the two files together? Meaning, what line(s) goes in here to make Tiramisu know to grab the SWEP entity data from that folder?

    rcs_ump.lua:
    Code:
    ITEM.Name = "UMP";
    ITEM.Class = "rcs_ump";
    ITEM.Description = "A sturdy, rapid-fire submachine gun.";
    ITEM.Model = "models/weapons/w_smg_ump45.mdl";
    ITEM.Purchaseable = true;
    ITEM.Price = 400;
    ITEM.ItemGroup = 3;
    ITEM.Offset = Vector( 4,-4,-2 )
    ITEM.OffsetAngle = Angle( 45,0,0 )
    ITEM.Bone = "chest"
    ITEM.WeaponType = "big"
    ITEM.Wearable = true
    
    
    function ITEM:Drop(ply)
    
    end
    
    function ITEM:Pickup(ply)
    
    	self:Remove();
    
    end
    
    function ITEM:UseItem(ply)
    
    	self:Remove();
    
    end
    The OA I worked with had a line like (in what would've been the custom SWEP):
    Code:
    ITEM.base = "weapon_base";
    ITEM.name = "UMP";
    ITEM.weaponClass = "rcs_UMP";
    That would point the item.lua file to the entities/weapons/rcs_ump/ folder, with the SWEP code.

    So I assume the same sort of thing applies here? "ITEM.Class = "rcs_ump";" points to the entities/weapons/rcs_ump/ folder. What sort of base do the default HL2RP weapons have then? I'm guessing the errors I'm getting are due to the shared.lua from either the weapon's SWEP code, or the weapon's base code, so does anyone have an example I can check out?

    Edited:

    Useful stuff.
    Thanks for the examples.

    Believe it or not, I had no trouble making other clothing/helmet items. That's pretty straightforward, since all you need to do really is duplicate another clothing item's fields and rename stuff, then change the model path to the new one.

    On the more advanced side of things, would there be a way to adjust where the player's head is if a certain clothing item was worn, or a specific helmet item was worn?

    For instance, the Balaclava on a standard citizen outfit makes the neck looked stretched, so is there a way to have the system adjust to something like that if the Balaclava is on? Maybe something like scaling the head down if the default clothes are on?

    Chances are the Balaclava might clip if it's vertically moved further down into the body, but I'm not sure if bones can be offset to begin with (through the item code).

  2. Post #402
    Gold Member
    Jawalt's Avatar
    August 2007
    3,478 Posts
    Add "weapon_" to the beginning of both the weapon and item class.

  3. Post #403
    LaughingLeader's Avatar
    July 2011
    19 Posts
    I attempted to try and get another type of SWEP working, to see if the root of the problems I've been having is RCS. So far, it appears to be working. The weapon shows up in my inventory, and right clicking on it to "Use" it keeps in the inventory, yet I also have it equipped in my weapon scroll menu

    Another difference here is that I renamed the folder in entity/weapons/ to "weapon_laserrifle", rather than the default "fo3_laserrifle" name it had. That way when I made the weapon item version, I could keep to the same weapon_name format.

    That gives me some certainty then that the errors I've had are from the shared.lua of the RCS weapons I've been trying to get to work, since making the weapon_laserrifle was as simple as setting that as the ITEM.Class name and making sure the equivalent folder in entities/weapons/ has the same name.

    The RCS weapons use HL2MP animations, so I'm guessing that conflicts with Tiramisu's animation system.

  4. Post #404
    HobomasterXXX's Avatar
    June 2009
    149 Posts
    Hey, as a quick suggestion, would it be possible to get the swimming animations that got patched in a while ago and add them to the animation tree files so you can swim properly in Tiramisu? Would be nice.

  5. Post #405
    Jocken300's Avatar
    February 2009
    1,361 Posts
    Hey, as a quick suggestion, would it be possible to get the swimming animations that got patched in a while ago and add them to the animation tree files so you can swim properly in Tiramisu? Would be nice.
    Should be as simple as going to sh_anim_tables and replacing line 19 with this:
    [ "swim" ] = "&switch:models/tiramisu/animationtrees/maleanimtree.mdl;ACT_SWIM",
    and then replacing line 216 with this:
    [ "swim" ] = "&switch:models/tiramisu/animationtrees/femaleanimtree.mdl;ACT_SWIM",

  6. Post #406
    HobomasterXXX's Avatar
    June 2009
    149 Posts
    Nope, I believe the .mdl files of the animation trees need to be recompiled with the new animations, cause that edit doesn't do anything but t-pose you.

  7. Post #407
    LaughingLeader's Avatar
    July 2011
    19 Posts
    I notice that some items (like the balaclava) have a line like this:

    ITEM.Offset = Vector( 0,-9,0 )

    Does that mean then that something like...
     ITEM.Scale = Vector( -1, -1, -1 )
    ...would actually scale the model down? I tried adding it to the balaclava, as the counterstrike player models are a little bit bigger than the HL2 player models, but I couldn't see a noticeable difference.
    Reply With Quote Edit / Delete Reply Windows 7 United States Show Events Agree Agree x 1 (list)

  8. Post #408
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    I notice that some items (like the balaclava) have a line like this:

    ITEM.Offset = Vector( 0,-9,0 )

    Does that mean then that something like...
     ITEM.Scale = Vector( -1, -1, -1 )
    ...would actually scale the model down? I tried adding it to the balaclava, as the counterstrike player models are a little bit bigger than the HL2 player models, but I couldn't see a noticeable difference.
    Yes, it does scale the model down, but in a different way that you may think, this only applies when said balaclava is stuck to the player's body as gear, which I don't think is what you want to do.

    For what you want to do, I coded something a long time ago. Go to global/plugins/clothing_gear/clothing.lua, head to the CAKE.HandleClothing function, and change this line:

    ply.Clothing[ ctype ]:SetDTInt( 3, 1 )

    To this.

    ply.Clothing[ ctype ]:SetDTInt( 3, CAKE.GetCharField(ply,"headratio")

    And then you can just do CAKE.SetCharField( ply, "headratio" ) to modify it on a per player basis. Please note, I don't remember why I took this off, it could probably fuck shit up massively, it could probably be buggy, but it does what you want to do which is resize the heads.
    Reply With Quote Edit / Delete Reply Windows 7 Venezuela Show Events Lua Helper Lua Helper x 2 (list)

  9. Post #409

    May 2011
    33 Posts
    i get a quite few of these often on my server "
    Too many vertex format changes in frame, whole world not rendered"
    can someone please tell me the fix to this?

  10. Post #410
    BluShell
    Cep.'s Avatar
    December 2011
    180 Posts
    i get a quite few of these often on my server "
    Too many vertex format changes in frame, whole world not rendered"
    can someone please tell me the fix to this?
    I'm willing to bet you're using rp_evocity. In any case, that "error" has nothing to deal with the gamemode, it's the map.

  11. Post #411

    May 2011
    33 Posts
    I'm willing to bet you're using rp_evocity. In any case, that "error" has nothing to deal with the gamemode, it's the map.
    i was actually using Rp_City11_Night_V1B, and when i press tab it doesnt show the menu it shows that its running sandbox =[
    EDIT: so whats the correct map?

  12. Post #412
    KatNotDinner's Avatar
    June 2011
    792 Posts
    Weird error, haven't come into it. Well some basic steps:
    Make sure you are running a dedicated server;
    Try switching the map;
    If you are running a dedi then make sure that you are loading Tiramisu.

  13. Post #413

    May 2011
    33 Posts
    im using NFOservers...... well i reinstalled my tiramisu and idk why but when i press tab it does not show the menu

    Edited:

    whats the main map that it is used for?

    so wait, which one should i download ffrom? github? SVN? or the garrysmod.org one ?

  14. Post #414
    KatNotDinner's Avatar
    June 2011
    792 Posts

    whats the main map that it is used for?

    so wait, which one should i download ffrom? github? SVN? or the garrysmod.org one ?
    I'm asking myself the same questions BUT:
    The github version is dev build so it might be unstable, it just allows Matt B and FNox to sync their work.
    The SVN should be the best as it was updated sooner than the gmod.org version.

    Edited:
    I can't tell you which map you should use as it seems that the gamemode doesn't need any special entities (which is the difference between Tiramisu and "professional" gamemodes like OA) so I guess that you can use any map.

  15. Post #415
    LaughingLeader's Avatar
    July 2011
    19 Posts
    Yes, it does scale the model down, but in a different way that you may think, this only applies when said balaclava is stuck to the player's body as gear, which I don't think is what you want to do.

    For what you want to do, I coded something a long time ago. Go to global/plugins/clothing_gear/clothing.lua, head to the CAKE.HandleClothing function, and change this line:

    ply.Clothing[ ctype ]:SetDTInt( 3, 1 )

    To this.

    ply.Clothing[ ctype ]:SetDTInt( 3, CAKE.GetCharField(ply,"headratio")

    And then you can just do CAKE.SetCharField( ply, "headratio" ) to modify it on a per player basis. Please note, I don't remember why I took this off, it could probably fuck shit up massively, it could probably be buggy, but it does what you want to do which is resize the heads.
    Thanks for this. It actually worked pretty good - I got that balaclava to not look so stretched on the default body.

    Unfortunately though, I started getting an error from the player data table, from this line:
    return CAKE.NilFix(CAKE.PlayerData[ CAKE.FormatText( ply:SteamID() ) ][ "characters" ][ ply:GetNWString( "uid" ) ][ fieldname ], CAKE.CharacterDataFields[ fieldname ]);
    The error was:
    [gamemodes\tiramisu\gamemode\player_data.lua:286] attempt to index field '?' (a nil value)
    As that error didn't really tell me what was wrong, and I had been slowly customizing Tiramisu, I wasn't positive on what I had done that caused the error. It would give me that when I hit the "Select" button from the character menu, and then proceeded to not load the character model until I spawned. I thought maybe I had bugged it somewhere in my modifications, so I went through some troubleshooting and reverted some files back to their original states, and even deleted my /data/ folder, in case one of the saved player data files was corrupt. None of that worked.

    The error finally stopped when I reverted the /clothing/ folder back to normal, so I'm assuming that might have been why you took the headratio line out. I'm not 100% positive on that though, as I had also reverted another file back to the original at the same time as the /clothing/ folder, but I'm pretty certain that's what probably did it.

    Edited:

    I'm asking myself the same questions BUT:
    The github version is dev build so it might be unstable, it just allows Matt B and FNox to sync their work.
    The SVN should be the best as it was updated sooner than the gmod.org version.
    I'm not sure if it's just me, but the Githhub version gave me a problem with the business menu, particularly located somewhere in the global/plugins/menu/ folder. Replacing that with the SVN version fixes it, so I'd go for using the SVN version right now.
    Reply With Quote Edit / Delete Reply Windows 7 United States Show Events Agree Agree x 1 (list)

  16. Post #416
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    OK guys, the official latest stable version is ALWAYS the garrysmod.org. GitHub releases are often stable, but not truly feature complete. Just let us finish up the new 2012 release.
    Reply With Quote Edit / Delete Reply Windows 7 Venezuela Show Events Friendly Friendly x 2 (list)

  17. Post #417
    Pycские Идиот
    LauScript's Avatar
    June 2010
    2,537 Posts
    reminder for fnox: make changelog
    Reply With Quote Edit / Delete Reply Windows 7 United States Show Events Agree Agree x 2 (list)

  18. Post #418

    May 2011
    33 Posts
    OK guys, the official latest stable version is ALWAYS the garrysmod.org. GitHub releases are often stable, but not truly feature complete. Just let us finish up the new 2012 release.
    nice, thanks! so what map is this gamemode good on?? and also what admin system do you prefer?? and when do you think is the release date for the 2012 update? sorry for the questions im just concerned :p

  19. Post #419
    fcampbell's Avatar
    May 2011
    91 Posts
    Invalid index passed to CStudioHdr()::GroupStudioHdr(): 4, but max is 0 [143342140]

  20. Post #420
    Exxon's Avatar
    January 2012
    347 Posts
    Any LUA coders need a box to put their Tiramisu edit on? Add me on Steam jakk_73

  21. Post #421
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    Invalid index passed to CStudioHdr()::GroupStudioHdr(): 4, but max is 0 [143342140]
    Not a Tiramisu error. If in Linux, check your installation.

  22. Post #422
    fcampbell's Avatar
    May 2011
    91 Posts
    Not a Tiramisu error. If in Linux, check your installation.
    What should I be checking it for?

  23. Post #423
    Gold Member
    Jawalt's Avatar
    August 2007
    3,478 Posts
    What should I be checking it for?
    Does it actually affect the workings of the script? If not, ignore it.

  24. Post #424
    fcampbell's Avatar
    May 2011
    91 Posts
    Does it actually affect the workings of the script? If not, ignore it.
    Crashes the server everytime I switch weapons.

  25. Post #425
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    Crashes the server everytime I switch weapons.
    Here's the good news, I'm working on something, I've got a Linux server now and therefore can test. I'll let you know through this thread if it is fixed.

  26. Post #426
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    Yep, it's fixed.

  27. Post #427
    Gold Member
    Jawalt's Avatar
    August 2007
    3,478 Posts
    Currently merging some things into the main Tiramisu branch:

    Serverside flashlights, now flashlights are actual lights.
    A STALKER schema.

    Edited:

    And I'm also working on containers, and some other shiz I'm contemplating.

  28. Post #428
    Dumb britbong
    C0MMUNIZT's Avatar
    April 2011
    1,922 Posts
    Maybe you guys could add something like,

    ITEM.ModelMale and ITEM.ModelFemale for clothing items?

    That way we don't have to make an item for each gender.

  29. Post #429
    Jocken300's Avatar
    February 2009
    1,361 Posts
    Maybe you guys could add something like,

    ITEM.ModelMale and ITEM.ModelFemale for clothing items?

    That way we don't have to make an item for each gender.
    That already exists.

  30. Post #430
    LaughingLeader's Avatar
    July 2011
    19 Posts
    Maybe you guys could add something like,

    ITEM.ModelMale and ITEM.ModelFemale for clothing items?

    That way we don't have to make an item for each gender.
    If you check out the code for clothing_formal.lua, you'll see something like this:

    ITEM.Model = "models/gman_high.mdl";
    ITEM.FemaleModel = "models/mossman.mdl"--This is the female model equivalent of this clothing item, this is optional

    You can use that same thing for other clothing items and change the female model to whatever you want.
    Reply With Quote Edit / Delete Reply Windows 7 United States Show Events Lua Helper Lua Helper x 1 (list)

  31. Post #431
    Dumb britbong
    C0MMUNIZT's Avatar
    April 2011
    1,922 Posts
    So I got back into messing with tira, Now when I click the menu buttons:

    Code:
    [tiramisu\gamemode\schemas\global\plugins\inventory\cl_inventory.lua:547] attempt to index field 'InventoryFrame' (a nil value)

  32. Post #432
    LaughingLeader's Avatar
    July 2011
    19 Posts
    So I got back into messing with tira, Now when I click the menu buttons:

    Code:
    [tiramisu\gamemode\schemas\global\plugins\inventory\cl_inventory.lua:547] attempt to index field 'InventoryFrame' (a nil value)
    Which version are you using? Use the garrysmod.org 1.2 release, as the others may have some bugs and such.

  33. Post #433

    December 2010
    47 Posts
    Which version are you using? Use the garrysmod.org 1.2 release, as the others may have some bugs and such.
    Happens in 1.2 and the git version.

  34. Post #434
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    Tiramisu 2 is under way, trust me, bug will be fixed.

    I can't fix bugs caused by you editing things or those caused by incompatibilities though, for obvious reasons.

  35. Post #435
    cam64DD's Avatar
    November 2008
    852 Posts
    hm, my character is invisible in third person mode. any ideas?

  36. Post #436
    VENEZOLANO
    Big Bang's Avatar
    August 2006
    3,419 Posts
    Changelog, until now, and still missing some things:

    --GENERAL


    * Added stamina. You can disable stamina consumption in configuration.lua

    * Modified camera. Thirdperson camera now only follows the player when aiming, therefore allowing freescroll around the

    character when not moving. Fixed the over the shoulder camera so it's slightly more accurate.

    * Bugfixes on the Options menu.

    * Added scaling for clothes. You can scale your body, head and hand size easily through the character editor.

    * Made running have acceleration, added new running animation. You're now unable to run at full speed while wielding a weapon.

    * Re-enabled the option of having your character's body visible in first person.

    * Changed the default font.

    * Schema color is now entirely modifiable in game through the Options menu.

    * Remade the entire HUD. No more portrait circle, no more cheesy 3D stuff.

    * Rewrote the chat code. Chat range is now calculated more realistically.

    * Added fade to black on death. Remade rp_acceptdeath, it uses a button now, no need to write anything in chat or console.

    * Added timer on rp_wakeup, therefore controlling the time you have to spend unconcious to wake up.

    * Finally fixed chat breaking after a certain amount of entries have been added to it.

    * Made chat channels use the current handler for talking. If you have the OOC channel selected you will talk in OOC, same with PMs

    * Added toggleable health regeneration.

    * Added right click option Make Into Clothing. Allows you to make clothing out of ragdolls, if they have the adequate skeleton.

    * Added right click options for permanent props and for tool trust.

    * Made inventory display currently worn items in red.

    * Added "Attach To" option to gear items, to allow their placement in bones other than those intended. Items can only be

    attached in one bone at a time, but any amount of items can be placed in any bone.

    * Fixed the camera. It should now strictly rely on the raw mouse feed, not on the AimAngle which is relative to FPS. Performance

    should be the same irregardless of current framerate.

    * Added setpermamodel, to set a player's permanent model, admin only.

    * Added swimming and vehicle driving animations.

    * Changed some animations around, combine and metro police animations are no longer used.

    -- SCRIPT

    * Rewrote clothing code. The whole thing, including player_part. It should now be readable.

    * Rewrote free scroll camera, no longer does it require the mouse to be visible.

    * Removed that ugly HiddenButton shit in favor of GUIMousePressed. Right clicking should now be more accurate

    * Removed right click shader.

    * Added fix for when new fields are added/removed, CAKE.NilFix simply didn't do shit.

    * Serverside flashlights

    * Bugfixes on the Options menu.

    * Moved ALL the configuration options to configuration.lua, including clientside options too, this is to easen up the task of editing Tiramisu

    * Moved ALL the VGUI and HUD drawing hooks to a single cl_skin.lua file, using derma.Hook. You can now change the way each and every element of the schema looks just by modifying a single file.
    Reply With Quote Edit / Delete Reply Windows 7 Venezuela Show Events Lua King Lua King x 3 (list)

  37. Post #437
    Ah... tits!
    sam6420's Avatar
    August 2009
    4,415 Posts
    I came.
    Reply With Quote Edit / Delete Reply Canada Show Events Agree Agree x 1 (list)

  38. Post #438
    LaughingLeader's Avatar
    July 2011
    19 Posts
    Looks like there's awesome stuff ahead for Tiramisu 2.0.

    How difficult would it be to make the business menu unlinked from groups? A standalone flag system for players. Having a certain flag gives you access to the defined item groups, yet you can be a part of whatever group you want. I'd like to take that even further by having an item (perhaps called a "Supplies License") that gives the holder access to a certain business menu, but I'd settle for a flag system detached from the group system.

    As it is right now, players have to be part of a pre-defined group that's been granted buygroup access, which limits the ability for players to be part of their own groups if they want to access the business menu. Unless there's already a way around that and I'm unaware, I think unlinking the business menu from the groups system and having a separate flag system could provide more creative freedom for players.

    Looks like there's a lot of great features coming in 2.0 though, so I'm excited.

    hm, my character is invisible in third person mode. any ideas?
    Unless this is a common issue (which it isn't, to my knowledge), you're probably going to have to provide more factors so the root of the problem can be found. If you didn't edit anything and are running on a fresh install of Tiramisu 1.2, then what might be happening is an addon is conflicting with Tiramisu and causing that to happen.

    Stuff to consider:
    1) What edits did you make to Tiramisu, if any?
    2) What version are you running?
    3) What addons do you have installed?
    4) Are you running Tiramisu in Singleplayer, or is this happening on a server?
    5) Are there any LUA errors in the console?

  39. Post #439

    October 2005
    46 Posts
    Can someone please explain to me buy groups and how people join a group they didnt create.

  40. Post #440
    Plenti's Avatar
    December 2011
    118 Posts
    This truly is a great gamemode and I wish more servers used it.