AssaultCube Reloaded Forums
Pickups and scripting - Printable Version

+- AssaultCube Reloaded Forums (https://acrf.victorz.ca)
+-- Forum: Modding (https://acrf.victorz.ca/forum-39.html)
+--- Forum: Modelling (https://acrf.victorz.ca/forum-38.html)
+--- Thread: Pickups and scripting (/thread-708.html)



Pickups and scripting - -{ET}-xdEpicZombie - 2013-01-27

The rotation and floating of pickups are done with cubescript.Could anyone script it so the pickups stay on the ground,dont rotate and float?


RE: Pickups and scripting - Victor - 2013-01-27

No, it's done with C++ code.
entities.cpp:13-19
Code:
void renderent(entity &e)
{
    const char *mdlname = entmdlnames[e.type-I_CLIPS];
    float z = (float)(1+sinf(lastmillis/100.0f+e.x+e.y)/20),
          yaw = lastmillis/10.0f;
    rendermodel(mdlname, ANIM_MAPMODEL|(e.spawned ? 0 : ANIM_TRANSLUCENT)|ANIM_LOOP|ANIM_DYNALLOC, 0, 0, vec(e.x, e.y, z+S(e.x, e.y)->floor+e.attr1), yaw, 0);
}



RE: Pickups and scripting - -{ET}-xdEpicZombie - 2013-02-01

What ever it is,can you do it?


RE: Pickups and scripting - Victor - 2013-02-02

Yes, but why would I do it?


RE: Pickups and scripting - -{ET}-xdEpicZombie - 2013-02-03

to make the gam look a bit more realistic-floating ammo boxes and grenades arent

or what u think

by the way if u do it we need new akimbo pickup model,Ill get it if needed


RE: Pickups and scripting - Victor - 2013-02-03

Well, it looks better with the floating ammo boxes, so it's considered a feature to have them float and rotate, but in real life, they wouldn't be there anyways.

Regarding the akimbo model, I'm not sure if it needs to be replaced.


This forum uses Lukasz Tkacz MyBB addons.